Check out Yvon Pedron's work on
creating an EJB logicsheets for cocoon based systems.

http://perso.club-internet.fr/pedron/ejb/

Please keep us posted on how this works for you.

/David



-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of
[EMAIL PROTECTED]
Sent: Wednesday, February 14, 2001 7:21 AM
To: jBoss
Subject: Re: [jBoss-User] Deployement error Warning: The return type
ofan ejbCreate(...) method must be the entity bean's primary key type.


Look at your deployment descriptor

<prim-key-class>java.lang.String</prim-key-class>

Shouldn't your primary key be defined as CategoryPK?

-Pete





"Indika Fernando" <[EMAIL PROTECTED]> on 02/14/2001 01:51:57 AM

Please respond to "jBoss" <[EMAIL PROTECTED]>

To:   "jboss" <[EMAIL PROTECTED]>
cc:    (bcc: Peter Cetinski/GELCO)

Subject:  [jBoss-User] Deployement error Warning: The return type of an
      ejbCreate(...) method must be the entity bean's primary key type.



hi all,
I am wriiting an BMP beans and using the jboss server...
my create method is given below:
In the Bean ::::
public CategoryPK ejbCreate(String catID,String catName,int hierarchyLevel,
           String parentCode,String description,String image)
                  throws CreateException, RemoteException
 {
    alll the stuff that is needed
    return new CategoryPK(catID);
}

My Home Interface is::::
Category create(String catID,String catName,int hierarchyLevel,
                    String parentCode,String description,String image)
throws CreateException,RemoteException;

But when I deploy the following errors were given::::::

Bean   : CategoryBean
Method : public CategoryPK ejbCreate(String, int, String, String, String)
throws
CreateException, RemoteException
Section: 9.2.3
Warning: The return type of an ejbCreate(...) method must be the entity
bean's
primary key type.

[Verifier]
Bean   : CategoryBean
Method : public CategoryPK ejbFindByPrimaryKey(CategoryPK) throws
FinderExceptio
n, RemoteException
Section: 9.2.5
Warning: The return type of the ejbFindByPrimaryKey method must be the
primary k
ey type.

my DEPLOYMET DESCRIPTOR
(Part of it is given below...)
<entity>
      <description>Category</description>
      <ejb-name>CategoryBean</ejb-name>
      <home>com.sr.espada.se.services.catman.CategoryHome</home>
      <remote>com.sr.espada.se.services.catman.Category</remote>
      <ejb-class>com.sr.espada.se.services.catman.CategoryBean</ejb-class>
      <persistence-type>Bean</persistence-type>
      <prim-key-class>java.lang.String</prim-key-class>
      <reentrant>False</reentrant>
   <cmp-field><field-name>catID</field-name></cmp-field>
      <cmp-field><field-name>catName</field-name></cmp-field>
      <cmp-field><field-name>creationDate</field-name></cmp-field>
      <cmp-field><field-name>hierarchyLevel</field-name></cmp-field>
      <cmp-field><field-name>parentCode</field-name></cmp-field>
      <cmp-field><field-name>description</field-name></cmp-field>
      <cmp-field><field-name>image</field-name></cmp-field>
   <primkey-field>catID</primkey-field>
    </entity>

<session>
      <description>CategoryCollection</description>
      <ejb-name>CategoryCollectionBean</ejb-name>
      <home>com.sr.espada.se.services.catman.CategoryCollectionHome</home>
      <remote>com.sr.espada.se.services.catman.CategoryCollection</remote>

<ejb-class>com.sr.espada.se.services.catman.CategoryCollectionBean</ejb-clas
s>
      <session-type>Stateless</session-type>
      <transaction-type>Bean</transaction-type>
   <ejb-ref>
         <ejb-ref-name>ejb/Category</ejb-ref-name>
         <ejb-ref-type>Entity</ejb-ref-type>
         <home>com.sr.espada.se.services.catman.CategoryHome</home>
         <remote>com.sr.espada.se.services.catman.Category</remote>
         <ejb-link>CategoryBean</ejb-link>
   </ejb-ref>
    </session>







--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
List Help?:          [EMAIL PROTECTED]









--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
List Help?:          [EMAIL PROTECTED]




--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
List Help?:          [EMAIL PROTECTED]

Reply via email to