-
1. Re: SFSB caching average and passivation remover timers
starksm64 Jan 20, 2006 3:28 AM (in response to ben.wang)I don't see why there should be an expectation that the session should be recoverable based on these settings. Explain the issue with a 2 count pool in more detail in terms of how it relates to this config as I'm not following what is special about it.
-
2. Re: SFSB caching average and passivation remover timers
ben.wang Jan 20, 2006 3:54 AM (in response to ben.wang)Ok, I will try to explain it one more time. Hope it is clearer.
The issue is when both are set to 3600 (secs). Users expect to see the bean goes away in one hour. If, however, the pool size is set to 2, after creating the 3rd bean, bean #1 will be passivated. Next when the remover thread comes in to check for ageout items to remove, bean #1 will be removed immediately (instead of 3600 seconds later). This is because the remove thread determine when to remove the passivated bean based on the delta of (max-bean-life and max-bean-age). -
3. Re: SFSB caching average and passivation remover timers
starksm64 Jan 20, 2006 4:40 AM (in response to ben.wang)Ok, but for max-bean-life == max-bean-age I would expect this. What else would you expect?
-
4. Re: SFSB caching average and passivation remover timers
ben.wang Jan 20, 2006 4:47 AM (in response to ben.wang)yeah, but in that example, I'd expect both max-bean-age and max-bean-life to be both 3600 seconds (so the bean should last for one hour). But in reality, the bean can be removed in 10-15 seconds after it has been passivated (because of pool size limit). Do you know what I am saying?
-
5. Re: SFSB caching average and passivation remover timers
starksm64 Jan 20, 2006 12:34 PM (in response to ben.wang)Ok, the bean is being passivated due to the size of the cache and subsequently removed because of the maxLifeAfterPassivation=0. This is a flaw in the logic of the removePassivated method. This code is assuming a time based passivation policy. The maxLifeAfterPassivation elapsed time needs to be calculated based on the inactive period of the bean, not the max-bean-age - max-bean-life diff because there is no correlation between these if the bean is evicted due to size.