Removal and Idle Timeout
Hello:
I've many doubts about these two settings parameters : <b>Removal Timeout</b> and <b>Idle Timeout</b> , in Containers , EJB Container , EJB Settings , Default Cache Settings.
I've read that <b>Idle Timeout</b> is the maximum time in seconds that a bean can remain idle in the cache. Afterwards, this bean become candidate to be passivate.
I've read that <b>Removal Timeout</b> specifies the amount of time in seconds a bean instance can remain idle in the container before it is removed
But, if Removal T. > Idle T., Statefull Session Bean isn't passivated ( because ejbPassivated isn't called )
For example :
Removal T. = 60
Idle T. = 30
Nothing happens and I can work fine.
But
Removal T. = 30
Idle T. = 60
session bean is passivated ( ejbPassivated is called ) at 1m 20s
Why ?
Indeed , I have read that if removal-timeout is less than or equal to cache-idle-timeout, beans are removed immediately without being passivated, but does't happen (?)
Anyone knows the right operation ? any documentation about this ?
Thanks in advance
Best regards
[1235 byte] By [
Grohl] at [2007-11-25 22:28:54]

# 1
Hi Grohl: Typically, when cache-idle-timeout < removal-timeout, ejbPassivate() is called and then the bean is serialized and saved into the session store. By default, the store is the session-store directory under the instance-root (which is typically domains/domain1/session-store).
When removal-timeout <= cache-idle-timeout, the bean is NOT passivated (or stored) to the session store. However, ejbPassivate is still called to allow the bean to free up any resources. So, in your case, though you are seeing calls to ejbPassivate, you should not see entries (or files) under the session-store directory.
Looks like the document must use the word stored instead of passivated in this case.
# 2
Thanks.
But my problem is that I want to force storing session, but I don't know how.
If I set cache-idle-timeout < removal-timeout , and cache-idle-timeout = 20 sec & removal-timeout=5400, ejbPassivate() is never called ( because I've got a output trace line in this method )
Could be that ejbPassivate() was never called, but looking at store session directory, I dont see any EJB stored
How I can force storing session ? Which server parameters are important during storing EJB session ?
Thanks in advance
Best regards
Grohl at 2007-7-5 2:38:34 >

# 3
Hi
I have some entries in my log that says :
com.sun.jdo.api.persistance.JDOObjectNotFoundException: Object does not exist in the data store.
FailedObjectArray: [se.pliktverket.services.clapersn.entity.EbAnvBean_1045879550_JDOState@18a09c41 ]
It is refering to an entitybean.
Is this related to this discussion about removal and idle timeout ?
We use some stateful sessionbeans and it is quit possible that the user (who is on s Swing-client) has been inactive for quite a long time.
TIA
Jan