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 EJB and other Java EE Technologies and the fly likes How to correctly instate SLSB from another archive? 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 » EJB and other Java EE Technologies
Bookmark "How to correctly instate SLSB from another archive?" Watch "How to correctly instate SLSB from another archive?" New topic
Author

How to correctly instate SLSB from another archive?

Michal Glowacki
Ranch Hand

Joined: Mar 14, 2006
Posts: 114
hi,

I have created separate JAR archive with my session beans that I use in multiple seam web projects. However, when I try to use it, entity manager defined in the session bean is always null

I declare entity manager in my outside session beans like this:


Then I try to instantiate in my seam project in multiple ways:



All the time entityManager variable is null and I can't operate on data from database.

I've been stuck with this for 3 days now, google, searching forums gives me no hints. Perhaps here anyone could give me a hint? At least a clue, if it's seam or my jar archive related problem. Persistence unit is declared in another JAR - with entity beans. However seam projects as well as message driven beans (also separare jar archive) can use it without problems. My guess is I instate the SLSB in the wrong way...

My archives structure on the server looks like this:

(/jboss5/server/default/deploy/)

/EntityBeans.jar
/SessionBeans.jar
/MessageDrivenBeans.jar
/MyWebApp.war
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to correctly instate SLSB from another archive?
 
Similar Threads
Seam Book (Yuan & Heute) Hello World Example Annotation
IsEntityRemovalAllowed
One of more persistence context for separate projects?
Access to entity manager in Session Bean
NullPointer with EntityManager in Entity Bean