• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Tricky question (How to pass javax.ejb.Handle)

 
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a J2EE project which has two WARs and one EJB JAR.
The only EJB is a stateful session bean which was created
to maintain client state (according to Java Blueprints best
practices). To be able to access this stateful
bean I have to pass javax.ejb.Handle object from one web module
to another.
The question is how can I do it? If there exist some easy way to
pass this object between two web modules, then why do I need the
stateful session bean?
 
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Put the handle in a location that both web modules can access.
 
Qand Davaatsedev
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I can put the client state there as well.
What's the point to store client state in a SFSB then?
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
SFSB are not shared. They can be thought of as logical extension of the client but running on an EJB container. EJB container provides tx,security support.

Originally posted by Qand Davaatsedev:
I can put the client state there as well.
What's the point to store client state in a SFSB then?

reply
    Bookmark Topic Watch Topic
  • New Topic