Hi All,
I am deploying a simple Hello Session Bean. I created an jar archive that contains the ejb-jar.xml in metainf folder. The below shows the ejb-jar.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
<ejb-jar>
<enterprise-beans>
<session>
<display-name>HelloWorld</display-name>
<ejb-name>HelloWorld</ejb-name>
<ejb-class>exapmple.HelloBean</ejb-class>
<remote>example.Hello</remote>
<home>example.HelloHome</home>
<local>example.HelloLocal</local>
<local-home>example.HelloLocalHome</local-home>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
</enterprise-beans>
</ejb-jar>
When i am deploying the jar archive i am getting the following error:
[Deployer:149034]An exception occurred for task [Deployer:149026]Deploy application HelloWorld on b2bsys1.: Exception:weblogic.management.ApplicationException: Prepare failed. Task Id = 3 Module: HelloWorld Error: [
EJB:011024]The XML parser encountered an error in your deployment descriptor. Please ensure that your deployment descriptor corresponds to the format in the DTD. The error was: Error parsing file 'META-INF/ejb-jar.xml' at line: 32 column: 13. The content of element type "session" must match "(description?,display-name?,small-icon?,large-icon?,ejb-name,home?,remote?,local-home?,local?,ejb-class,session-type,transaction-type,env-entry*,ejb-ref*,ejb-local-ref*,security-role-ref*,security-identity?,resource-ref*,resource-env-ref*)".. .
It seems there is a problem in ejb-jar.xml. Can you tell IS there anything that i am doing wrong.
Thanks in advance.
Sanjay.