File tree Expand file tree Collapse file tree
src/main/java/eu/openanalytics/containerproxy/service/session/undertow Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -36,12 +36,7 @@ public class CustomSessionManagerFactory implements SessionManagerFactory {
3636 @ Override
3737 public SessionManager createSessionManager (Deployment deployment ) {
3838 if (inMemorySessionManager == null ) {
39- inMemorySessionManager = new InMemorySessionManager (
40- deployment .getDeploymentInfo ().getSessionIdGenerator (),
41- deployment .getDeploymentInfo ().getDeploymentName (),
42- -1 ,
43- false ,
44- deployment .getDeploymentInfo ().getMetricsCollector () != null );
39+ inMemorySessionManager = new CustomInMemorySessionManager (deployment );
4540 }
4641 return inMemorySessionManager ;
4742 }
@@ -50,4 +45,22 @@ public InMemorySessionManager getInstance() {
5045 return inMemorySessionManager ;
5146 }
5247
48+ private static class CustomInMemorySessionManager extends InMemorySessionManager {
49+
50+ public CustomInMemorySessionManager (Deployment deployment ) {
51+ super (deployment .getDeploymentInfo ().getSessionIdGenerator (),
52+ deployment .getDeploymentInfo ().getDeploymentName (),
53+ -1 ,
54+ false ,
55+ deployment .getDeploymentInfo ().getMetricsCollector () != null );
56+ }
57+
58+ @ Override
59+ public void stop () {
60+ // do not destroy sessions on shutdown (they are stored only in memory)
61+ // see #35406
62+ }
63+
64+ }
65+
5366}
You can’t perform that action at this time.
0 commit comments