Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

EJBC Error  RSS feed

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I get an error when I run weblogic.ejbc (webogic6sp2):
ERROR: Error from ejbc: Bean 'MusicCDBean' is a CMP entity bean, but does not declare the persistence type that it uses. Cannot deploy the bean.
However, I did declare the persistence type in the ejb-jar.xml as follows:
<persistence-type>Container</persistence-type>
but still get the above error. Could anyone give me advise/help on this problem?
Thank you.


------------------
- Stephen
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oooops, I was using a Container Managed Entity Bean and looks like Weblogic needs to define a persistence-type both in ejb-jar.xml and weblogic-ejb-jar.xml plus a new weblogic-cmp-rdbms-jar.xml. I'll give this a try first and post the results...
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Compiling again, i get the following errors:
ERROR: Error from ejbc: [9.4.7.2] In EJB MusicCDBean, the primary key class java.lang.String has a field named CASE_INSENSITIVE_ORDER which is static.
No field in the primary key class may be static.
I can't seem to find a solution here. Somebody knows a similar problem? Please send a probable solution. Thank you.
------------------
- Stephen
 
Tim Holloway
Bartender
Posts: 18709
71
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Odds are that you specified the key with a <primary-key-class> XML instead of <primary-key-field>. The two are mutually exclusive.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!