Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Deploying entity beans with Local Interfaces

 
Ranch Hand
Posts: 379
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I developed a very simple entity bean and I used local interfaces, because I want to use a session bean facade to access the entity bean. During deployment on Jboss I get the following exception:
<!-- Exception begin -->
22:51:14,390 WARN [verifier] EJB spec violation:
Bean : UsersEJB
Section: 9.2.2
Warning: The entity bean class must not be defined as abstract.
22:51:14,390 WARN [verifier] EJB spec violation:
Bean : UsersEJB
Section: 9.4.7.1
Warning: The primkey-field element must name a public field in the bean implemen
tation class.
<!-- Exception end -->
I developed the implementation class as abstract because it contains some abstract getter and setter methods, according to the EJB 2.x specs. Is it possible to deploy and implementation class as an abstract class? Why I'm getting this error?
Thanks,
Marco
 
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I can't offer anything wise on this, but I just encountered the second of those warnings. I would only suggest checking your ejb-jar.xml file for errors and making sure it corresponds to the fields in your bean.
 
Author
Posts: 367
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Check the DOCTYPE on your ejb-jar.xml and jboss.xml files. You are probably using old ones that tell JBoss you want to use EJB 1.1. Here is what I am using to deploy an EJB 2.0 app on jboss 3.0.x.
ejb-jar.xml:
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
jboss.xml:
<!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 3.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_3_0.dtd">
 
I have always wanted to have a neighbor just like you - Fred Rogers. Tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic