• 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

Stateful Session Bean

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can I say a session scope in JSP bean as Stateful session bean?
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Come again? If you're asking whether a JavaBean stored into HttpSession with session scope is a stateful session bean, the answer is no. If you're asking whether you can store a reference to a stateful session bean into HttpSession with session scope, the answer is yes but only by breaking the rules. The reference isn't serializable, which is required by the spec for all objects put into HttpSession but in practice you can get away with unserializable objects in HttpSession as long as you don't have a cluster (i.e. the container doesn't attempt to serialize the objects).
 
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Ashok Jaganathan:
Can I say a session scope in JSP bean as Stateful session bean?


If you are just comparing the way these two work , Yes.
Both have an identifier and maintain the session state with the calling client. Obviously, the purpose and the mechanism are very diff.
 
Ashok Jaganathan
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Lasse and Rangarajan for your replies.Rangarajan can you briefly tell me in what way the purpose and mechanism are different.
reply
    Bookmark Topic Watch Topic
  • New Topic