New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Jetty 9.4.x 2140 infinispan expired sessions #3457
Jetty 9.4.x 2140 infinispan expired sessions #3457
Conversation
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
…140-InfinispanExpiredSessions Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
deserialisation; classname of hotrod remote cache has changed Signed-off-by: Jan Bartel <janb@webtide.com>
just with query.
…40-InfinispanExpiredSessions
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice job (maybe some very minor/cosmetic changes)
...y-hazelcast/src/main/java/org/eclipse/jetty/hazelcast/session/HazelcastSessionDataStore.java
Outdated
Show resolved
Hide resolved
...y-hazelcast/src/main/java/org/eclipse/jetty/hazelcast/session/HazelcastSessionDataStore.java
Outdated
Show resolved
Hide resolved
...y-hazelcast/src/main/java/org/eclipse/jetty/hazelcast/session/HazelcastSessionDataStore.java
Show resolved
Hide resolved
...an-sessions/src/test/java/org/eclipse/jetty/server/session/ClusteredOrphanedSessionTest.java
Outdated
Show resolved
Hide resolved
@@ -24,6 +24,7 @@ | |||
import org.eclipse.jetty.session.infinispan.InfinispanSessionDataStoreFactory; | |||
import org.junit.jupiter.api.AfterAll; | |||
import org.junit.jupiter.api.BeforeAll; | |||
import org.junit.jupiter.api.Test; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unused import
.../test/java/org/eclipse/jetty/server/session/remote/RemoteClusteredSessionScavengingTest.java
Outdated
Show resolved
Hide resolved
|
||
baos = new ByteArrayOutputStream(); | ||
IO.copy(is, baos); | ||
is.close(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need to close
Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
I've just found an issue with hazelcast, so don't merge this PR yet until I can resolve it. Basically, the problem is that if I enable indexing on the SessionData.expiry field, then for some reason, hazelcast then uses a separate thread to re-read the SessionData after storing it! So far I haven't been able to find a way to avoid this - I may have to make it configurable whether to support queries on hazelcast, with the documented caveat that if you do, you won't be able to store session attributes of classes that exist only inside the webapp. |
Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
environment work for serialization/deserialization. Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
…40-InfinispanExpiredSessions Signed-off-by: Jan Bartel <janb@webtide.com>
Signed-off-by: Jan Bartel <janb@webtide.com>
…40-InfinispanExpiredSessions
#2140
Adds the ability to Infinispan and Hazelcast to query to find expired sessions, as per the other SessionDataStores. This means that sessions can be scavenged by jetty (rather than relying on configuring infinispan or hazelcast with time-to-live on each entry), so HttpSessionListeners can be correctly called when the sessions are scavenged.
At the same time, infinispan has been updated to version 9.4.8, and support for the old infinispan-7 dropped.