Thanks for your kind reply!

[EMAIL PROTECTED] schrieb:

> What do you think about stateful session beans?
> For example, if you take the stateful session bean, you have the
> conversational state. Having the big cache you can expect that your bean
> will remain in memory. At least, when the bean is to be removed from the
> cache, you'll get a passivation event (ejbPassivate). And you can start your
> calculations on activation (ejbActivate) or creation (ejbCreate).

The problem with session bean is, as far as I understand, every session
is unique. So if I calculate the state in one session, then it won't be
accessible next time I invoke the session bean, although the data has
not changed. I can never get to the same session bean again, which
defeats the purpose of caching.

> Also I do not see any problem with storing buffer content in serialized form
> into some database record. If you say that calculations are costly, then
> storing data in DB will not be so costly, probably even less than 1% of the
> total execution time.

Not really sure about it myself, maybe it's the last resort if
everything else failed;-)

regards
ZHU Jia

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to