Hi,

its not a jboss problem. Every SLSB must define at least one ejbCreate
method :)

public class MyBean implements SessionBean

        // create the bean with no parameters
        public void ejbCreate() {}      

        // create the bean with one parameter
        public void ejbCreate(String name) {}   

   public void ejbActivate()
   {
   }

   public void ejbPassivate()
   {
   }

   public void ejbRemove()
   {
   }

   public void setSessionContext(SessionContext ctx) throws EJBException
   {
   }
}

-thomas

> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of 
> Elankath, Tarun (Cognizant)
> Sent: 04 March, 2004 13:21
> To: [EMAIL PROTECTED]
> Subject: [JBoss-user] Ejb Deployment error stating "spec 
> violation" making me go mad
> 
> Hi all,
> 
> I am a bit new to jboss, so please forgive me if this is 
> something very stupid.
> When I try to deploy my ejb.jar file (by creating a hard-link 
> from the jboss deploy directory to my devel directory) I am 
> using xdoclet to generate the ejb and jboss deployment descriptors.
> I always get the following error:
> 
> 17:45:14,242 WARN  [verifier] EJB spec violation:
> Bean   : Acknowledgement
> Section: 7.10.3
> Warning: A Session bean must define at least one ejbCreate method.
> 
> 17:45:14,282 WARN  [verifier] EJB spec violation:
> Bean   : Acknowledgement
> Section: 7.10.2
> Warning: Session bean class must not be abstract.
> 
> 17:45:14,362 ERROR [MainDeployer] could not create deployment:
> file:/E:/Servers/
> jboss-3.2.3/server/default/deploy/tier2ejb.jar/
> org.jboss.deployment.DeploymentException: Verification of 
> Enterprise Beans faile d, see above for error messages.
> 
> 
> Now, my acknowledgement bean is _definitely_ not abstract and 
> definitely possesses a ejbCreate method.
> Both ejb-jar.xml and jboss.xml get generated into a META-INF/ 
> subdirectory of my linked directory.
> My ejb-jar.xml looks like this: (snippet)
>     <session >
>          <description><![CDATA[Bean implementation class for 
> Enterprise
> Bean: Acknowledgement]]></description>
> 
>          <ejb-name>Acknowledgement</ejb-name>
> 
>  
> <home>com.adp.magellan.acknowledge.ejb.AcknowledgementHome</home>
>  
> <remote>com.adp.magellan.acknowledge.ejb.Acknowledgement</remote>
>  
> <local-home>com.adp.magellan.acknowledge.ejb.AcknowledgementLo
> calHome</l
> ocal-home>
>  
> <local>com.adp.magellan.acknowledge.ejb.AcknowledgementLocal</local>
>  
> <ejb-class>com.adp.magellan.acknowledge.ejb.AcknowledgementBea
> n</ejb-cla
> ss>
>          <session-type>Stateless</session-type>
>          <transaction-type>Container</transaction-type>
> 
>       </session>
> 
> And my jboss.xml snippet looks like this:
>      <session>
>          <ejb-name>Acknowledgement</ejb-name>
>          <jndi-name>Acknowledgement</jndi-name>
>          <local-jndi-name>AcknowledgementLocal</local-jndi-name>
> 
>         <method-attributes>
>         </method-attributes>
>       </session>
> 
> All help/pointers much appreciated,
> Thanks & Regards,
> Tarun
> 
> 


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id70&alloc_id638&op=click
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to