this is an interesting topic. You have the following choices:
1) no session state cached anywhere other than a sessionId in a cookie or embeded in url. end user re-submit all information again and again for the following requests. it is something like, when you are in phone call with somebody, everytime you say something beginning with, 'this is denis speaking, previously we just talked about step1, now i am going to talk about step2."
2) cached in web application using HttpSession
3) cached using stateful session beans
4) write it into database (or any permenant resource)
There are cases when 1) and 4) are definitely better choices.
Now let's just suppose you DO HAVE to cache your conversational status either in web layer or ejb layer.
httpSession is a straightforward solution with serialization. Stateful session beans are heavy because they have services for transaction, security, instance pooling, and etc. why not split their functionalities into two parts: httpSession takes care of the state-caching part and stateless sessionbeans take care of the transaction, security....
I have no clue why the author of the article make the following comments:
"Indeed, it seemed that the use of stateful beans should actually improve performance, since we would no longer need to wear the cost of serializing state relating to the application transaction to and from either the web tier or database upon each request."
Is activation/passivation coming free? Anyway the bottom line is stateful session beans have to use techniques similar to serizalization to cache the state if memory is not enough when hundreds of users hit the server simultaneously.
Forgive me if i am biased. Once I switched stateful ones into stateless ones to
boost performance dramatically with weblogic6.1. i'd rather trust my real experience.