I have the following xdoclet code to generate a ejbSpec=2.1 bean:

* @ejb.bean
*               display-name = "Human Resources Facade Bean"
*      jndi-name = "HRFacadeBean"
*      type = "Stateless"
*               transaction-type = "Bean"
*               view-type = "all"
* @ejb.util
*      generate = "physical"
*/

However when I deploy this bean in JBoss 4.0.0 I get a DeploymentException:
Bean : HRFacade
Method : public abstract EJBHome getEJBHome() throws RemoteException
Section: 7.11.9
Warning: No warning message found, please file a Bug report.
12:00:38,686 WARN [verifier] EJB spec violation: Bean : HRFacade
Method : public abstract boolean isIdentical(EJBObject) throws RemoteException
Section: 7.11.9
Warning: No warning message found, please file a Bug report.
12:00:38,702 ERROR [MainDeployer] could not create deployment: file:/D:/jboss-4.0.0/server/default/tmp/deploy/tmp32398ark-web-ears-ark-ear-SNAPSHOT.ear-contents/ark-web-ears-ark-ejb-SNAPSHOT.jar
org.jboss.deployment.DeploymentException: Verification of Enterprise Beans failed, see above for error messages.


I don't think that XDoclet is generating the correct Java files for deployment. 
I have verified that the ejb-jar.xml is of the correct spec version however.

I have attached my java file which has these tags in it. Also the generated 
ejb-jar.xml file

The methods that the deployment is failing on are generated from Xdoclet.

Do I need a different tag to correctly generate the service-endpoint tag 
correctly?

Thanks

--

Steven Lamb
e: [EMAIL PROTECTED]
p: 835 32718
w: www.animallogic.com

package com.al.ark.ejb.hr;

import java.util.List;

import com.al.ark.jms.TopicMessenger;

import javax.ejb.SessionBean;

import com.al.ark.bean.party.Person;
import com.al.ark.ejb.staff.StaffList;


/**
 * This class is a Facade containing all of the busniess operations that can be 
performed on a
 * Person object.
 *
 * @ejb.bean
 *              display-name = "Human Resources Facade Bean"
 *      jndi-name = "HRFacadeBean"
 *      type = "Stateless"
 *              transaction-type = "Bean"
 *              view-type="all"
 *
 * @ejb.util
 *      generate = "physical"
 */
public abstract class HRFacadeBean implements SessionBean {

    /**
     * @ejb.interface-method
     *                 view-type = "both"
     *
     * @param person The Person to create
     */
    public void createEmployee(Person person) {
    
        // This method was created as a dependency test and is a sample for how 
        // Stateless Session should be created
        // SpringFactory factory = SpringFactory.getInstance();
        // PersonDao personDao = (PersonDao) 
factory.getBean(PersonDao.SPRING_BEAN_ID);
        // personDao.saveOrUpdate(person);
        
        try
        {
            TopicMessenger messenger = new TopicMessenger();
            messenger.connect("topic/hrTopic");
                messenger.sendMessage("Hello World");
                messenger.close();
            }
        catch (Exception e)
        {
            e.printStackTrace();
        }
    }
    
    /**
     * @ejb.interface-method
     * 
     *                 view-type = "both"
     * 
     * Used to be both
     * @return A List of StaffEntry Objects
     */
    public List getStaffList() {
        
        return (StaffList.getInstance().getStaff());
    }
    
    /**
     * @ejb.interface-method
     *                 view-type = "both"
     * 
     * @param c Only return Staff whose first name starts with the specified 
character
     * @return A list of StaffEntry Objects
     */
    public List getStaffList(char c) {
        
        return (StaffList.getInstance().getStaff(c));
    }
    
}
<?xml version="1.0" encoding="UTF-8"?>

<ejb-jar  xmlns="http://java.sun.com/xml/ns/j2ee"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd"; version="2.1">

   <description><![CDATA[No Description.]]></description>
   <display-name>Generated by XDoclet</display-name>

   <enterprise-beans>

      <!-- Session Beans -->
      <session >
         <description><![CDATA[This class is a Facade containing all of the busniess operations that can be performed on a Person object.]]></description>
         <display-name>Human Resources Facade Bean</display-name>

         <ejb-name>HRFacade</ejb-name>

         <home>com.al.ark.ejb.hr.HRFacadeHome</home>
         <remote>com.al.ark.ejb.hr.HRFacade</remote>
         <local-home>com.al.ark.ejb.hr.HRFacadeLocalHome</local-home>
         <local>com.al.ark.ejb.hr.HRFacadeLocal</local>
      	 <service-endpoint>com.al.ark.ejb.hr.HRFacade</service-endpoint>
         <ejb-class>com.al.ark.ejb.hr.HRFacadeSession</ejb-class>
         <session-type>Stateless</session-type>
         <transaction-type>Bean</transaction-type>

      </session>

     <!--
       To add session beans that you have deployment descriptor info for, add
       a file to your XDoclet merge directory called session-beans.xml that contains
       the <session></session> markup for those beans.
     -->

      <!-- Entity Beans -->
     <!--
       To add entity beans that you have deployment descriptor info for, add
       a file to your XDoclet merge directory called entity-beans.xml that contains
       the <entity></entity> markup for those beans.
     -->

      <!-- Message Driven Beans -->
     <!--
       To add message driven beans that you have deployment descriptor info for, add
       a file to your XDoclet merge directory called message-driven-beans.xml that contains
       the <message-driven></message-driven> markup for those beans.
     -->

   </enterprise-beans>

   <!-- Relationships -->

   <!-- Assembly Descriptor -->
     <!--
       To specify your own assembly descriptor info here, add a file to your
       XDoclet merge directory called assembly-descriptor.xml that contains
       the <assembly-descriptor></assembly-descriptor> markup.
     -->

   <assembly-descriptor >
     <!--
       To specify additional security-role elements, add a file in the merge
       directory called ejb-security-roles.xml that contains them.
     -->

   <!-- method permissions -->
     <!--
       To specify additional method-permission elements, add a file in the merge
       directory called ejb-method-permissions.ent that contains them.
     -->

   <!-- finder permissions -->

   <!-- transactions -->
     <!--
       To specify additional container-transaction elements, add a file in the merge
       directory called ejb-container-transaction.ent that contains them.
     -->

   <!-- finder transactions -->

     <!--
       To specify an exclude-list element, add a file in the merge directory
       called ejb-exclude-list.xml that contains it.
     -->
   </assembly-descriptor>

</ejb-jar>

Reply via email to