This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Java in General and the fly likes JEE example with EJB, JSF is not working Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "JEE example with EJB, JSF is not working" Watch "JEE example with EJB, JSF is not working" New topic
Author

JEE example with EJB, JSF is not working

john wutka
Ranch Hand

Joined: Apr 14, 2011
Posts: 31

I am trying following example from link
http://javafootsteps.blogspot.com/p/java-ee-6-showcase.html?showComment=1330714830641
on netbeans 6.7.1 and glassfish server.

Netbeans is complaining about following annotations.
@Local
@Stateless

@Named
@ConversationScoped
@Inject

I imported ejb3-persistence jar as well. Not sure what other jar is missing. I am pasting source code for your reference. I tried to run

example as given in the tutorial on

Eclipse Galileo (SR2)
JBoss Tools 3.1.1 (JBossTools-Update-3.1.1.v201006011046R-H111-GA.zip)
JBoss AS 6 M3 (jboss-as-distribution-6.0.0.20100429-M3.zip)

But i could not get the JBOSS server software download. When i searched I was only able to download the update software not entire server software.(Please advise if you can point me to direct link where i can down load above vesion JBOSS AS). Reason I selected netbeans with Glasfish is i can have every thing in place without spending lot of time on configuration, setting up environments etc.







UserFacade interface file





UserFacadeBean File




UserService File



Then view files are

index.html file


layout.xhtml file


register.xhtml file




register_confirm file is




I do not see any source code with required libraries on that link as well.
Please advise on how to run this example effectively.



[Thumbnail for JEEExampleError.JPG]

Victor M. Pereira
Ranch Hand

Joined: Mar 02, 2012
Posts: 50
First, your lacking the imports.

javax.ejb package
javax.faces package
javax.persistance package
javax.enterprise.context package
javax.Inject.inject

Next, I'm not seeing your pom.xml neither the jta or the glassfish datasource.

Have you used jpa 2.0, jsf 2.0 or ejb 3.1 before?

You can try: How to Create a Java EE 6 Application with JSF 2, EJB 3.1, JPA, and NetBeans IDE 6.8


regards,
Victor M. Pereira
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JEE example with EJB, JSF is not working
 
Similar Threads
How to use <f:loadBundle> tag inside <ui:composition> tag
DataTable datas are not actual
JSF form problems
Again javax.el.PropertyNotFoundException
Bug in chrome