wood burning stoves*
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes stateful session EJB 3 question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "stateful session EJB 3 question" Watch "stateful session EJB 3 question" New topic
Author

stateful session EJB 3 question

Marx Villegas
Ranch Hand

Joined: Mar 10, 2006
Posts: 94
Hello ranchers,
are stateful session EJBs still a heavy-weigth object that one should avoid in designs?
Please correct me if I'm wrong, but it seems to me that stateful session beans are way lighter in EJB 3.0 than 2.X.
Thanks in advance...
XM


When the compiler's not happy, ain't nobody happy...
Marx Villegas
Ranch Hand

Joined: Mar 10, 2006
Posts: 94
Any thoughts anyone?
Horst Naujoks
Greenhorn

Joined: Jul 12, 2002
Posts: 12
I think the advice to avoid stateful session beans does't come from their cognition as "heavy weigth" objects. The true problem with sfsb is that they introduce higher demands on application servers in a clustered environment (transfering "state" from on server to another for the sake of failover, loadbalancing, etc.).
In my opinion, even with EJB3 it's still essential to carefully think about their usage.
Marx Villegas
Ranch Hand

Joined: Mar 10, 2006
Posts: 94
sounds reasonable...
Thanks
Marx
Dan Drillich
Ranch Hand

Joined: Jul 09, 2001
Posts: 1167
Marx,

The question whether to include stateful session beans in our design, was raised many times in this forum; many people are very determined to be on one side or the other.

Horst and many other fellows are reluctant to use stateful session beans, because of practical implementation issues that different application servers had and have with these beans.

However, as an architect you need to factor into your decision, the benefits of a particular technology and weigh it against the current/past implementation problems.

Personally, I think that Sun would be delighted to see stateful session beans in your design, whenever it's appropriate, and it's definitely appropriate in certain places in our solution.

Regards,
Dan


William Butler Yeats: All life is a preparation for something that probably will never happen. Unless you make it happen.
Marx Villegas
Ranch Hand

Joined: Mar 10, 2006
Posts: 94
Actually, I'll surely use 'em in my assignment. I was only very keen to know if the discussion was still valid for the lighter EJB3.
Thanks for your comments.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: stateful session EJB 3 question
 
Similar Threads
ejb container session replication different from HTTP session replication
HttpSession and Session Bean
Maintaing everthing in Session Object
HttpSession and Session Bean
Session Management in Clustering