Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

problem with ejb3 tutorial

 
shabarish vai
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all,

i have used the below link
http://wiki.netbeans.org/CreatingEJB3UsingNetbeansAndGlassfish
and not able to use annotations,also the above tutorial is creating ejb2.0 project structure

please help me with some examples for ejb3.0 as am preparing for scbcb5.0
 
Mark E Hansen
Ranch Hand
Posts: 650
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I used a tutorial which made use of Eclipse IDE with the JBossTools plug-in, deploying to JBoss AS 5.1.0.GA.
It definitely used EJB3.0 entities and includes session beans and a servlet. If you want to try this, here are two links. The first is a tutorial for installing all the necessary software, the second is the actual application tutorial:

http://www.wi.uni-muenster.de/pi/lehre/ss09/EAI/tutorials/tutorial_jboss_setup.html

http://www-wi.uni-muenster.de/pi/lehre/ss09/EAI/tutorials/tutorial_jboss_project.html

I hope this helps,
 
shabarish vai
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for the reply sir,
i modified prject.properties and web.xml and now am able to create session bean and local interface but hte problem is netbeans is not accepting annotations like @stateless,@local it is saying "cannot find symbol class Stateless".
Do i need to set classpath in project properties if so how and to which jar file i need to set
 
Mark E Hansen
Ranch Hand
Posts: 650
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The annotation is @Stateless, not @stateless. Are you sure you're specifying is correctly?
You can find it in the JavaEE API: http://java.sun.com/javaee/6/docs/api/ as javax.ejb.Stateless (in the Packages frame, select javax.ejb, then in the Classes frame, scroll down to Annotation Types).

As far as the Jar, you can just examine the Jar files to see which one contains it. I'm using JBoss, and did a quick search and found it in the JBOSS_HOME/client/jboss-javaee.jar Jar file. You should be able to do something similar with your application server.

Regards,
 
Anand Kumar Singh
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This can help you

http://www.jboss.org/file-access/default/members/jbossejb3/freezone/docs/tutorial/1.0.7/html/index.html
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!