CB-3418 fix incorrect session lifetime on easy config (#1686)

This commit is contained in:
Alexander Skoblikov
2023-05-24 14:03:10 +03:00
committed by GitHub
parent d888549bec
commit 6227e00467
2 changed files with 11 additions and 1 deletions
@@ -141,7 +141,7 @@ public class WebServerConfig {
@Property
public long getSessionExpireTime() {
return application.getMaxSessionIdleTime();
return application.getConfiguredMaxSessionIdleTime();
}
@Property
@@ -186,6 +186,9 @@ public abstract class CBApplication extends BaseWebApplication implements WebAut
return false;
}
/**
* @return actual max session idle time
*/
public long getMaxSessionIdleTime() {
if (isConfigurationMode()) {
return CONFIGURATION_MODE_SESSION_IDLE_TIME;
@@ -193,6 +196,13 @@ public abstract class CBApplication extends BaseWebApplication implements WebAut
return maxSessionIdleTime;
}
/**
* @return max session idle time from server configuration, may differ from {@link #getMaxSessionIdleTime()}
*/
public long getConfiguredMaxSessionIdleTime() {
return maxSessionIdleTime;
}
public CBAppConfig getAppConfiguration() {
return appConfiguration;
}