time-to-live: Maximum time in seconds for each entry to stay in the map. If it is not 0, entries that are older than and not updated for this time are evicted automatically. Valid values are integers between 0 and Integer.MAX VALUE. Default value is 0 and it means infinite. Moreover, if it is not 0, entries are evicted regardless of the set eviction-policy.
max-idle-seconds: Maximum time in seconds for each entry to stay idle in the map. Entries that are idle for more than this time are evicted automatically. An entry is idle if no get, put or containsKey is called. Valid values are integers between 0 and Integer.MAX VALUE. Default value is 0 and it means infinite.Hi Mikael,
Behavior is (a).
Max-idle works against last-access-time.
If you mix ttl & max-idle, entry will be evicted according to nearest one in time.
Some more details here: https://github.com/hazelcast/hazelcast/issues/3920
--
You received this message because you are subscribed to the Google Groups "Hazelcast" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hazelcast+...@googlegroups.com.
To post to this group, send email to haze...@googlegroups.com.
Visit this group at http://groups.google.com/group/hazelcast.
To view this discussion on the web visit https://groups.google.com/d/msgid/hazelcast/b4758ad6-c001-4bb6-a28b-9d5af479f5d3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
If it fits in your use case, using max-idle seems a better option instead of extending TTL in every set operation.
replace updates last-access-time and only affects max-idle expiration, nothing to do with TTL
To view this discussion on the web visit https://groups.google.com/d/msgid/hazelcast/a2ee1b47-1a3b-4d7d-ad69-c4749ed0e51b%40googlegroups.com.
IMap extends ConcurrentMap To view this discussion on the web visit https://groups.google.com/d/msgid/hazelcast/379ab31e-37dd-41e8-b252-04286b0dfcf7%40googlegroups.com.