public class DefaultDeploymentConfiguration extends PropertyDeploymentConfiguration
DeploymentConfiguration
based on a base
class for resolving system properties and a set of init parameters.Modifier and Type | Field and Description |
---|---|
static boolean |
DEFAULT_CLOSE_IDLE_SESSIONS
Default value for
isCloseIdleSessions() = false . |
static int |
DEFAULT_HEARTBEAT_INTERVAL
Default value for
getHeartbeatInterval() = 300 . |
static int |
DEFAULT_MAX_MESSAGE_SUSPEND_TIMEOUT
Default value for
getMaxMessageSuspendTimeout() ()} = 5000 . |
static boolean |
DEFAULT_SEND_URLS_AS_PARAMETERS |
static boolean |
DEFAULT_SYNC_ID_CHECK
Default value for
isSyncIdCheckEnabled() = true . |
static int |
DEFAULT_WEB_COMPONENT_DISCONNECT
Default value for
getWebComponentDisconnect() = 300. |
static String |
NOT_PRODUCTION_MODE_INFO |
static String |
NOT_PRODUCTION_MODE_WARNING |
static String |
WARNING_COMPATIBILITY_MODE |
static String |
WARNING_HEARTBEAT_INTERVAL_NOT_NUMERIC |
static String |
WARNING_LIVERELOAD_DISABLED_AND_NEW_LICENSE_CHECKER |
static String |
WARNING_PUSH_MODE_NOT_RECOGNIZED |
static String |
WARNING_XSRF_PROTECTION_DISABLED |
Constructor and Description |
---|
DefaultDeploymentConfiguration(Class<?> systemPropertyBaseClass,
Properties initParameters)
Create a new deployment configuration instance.
|
Modifier and Type | Method and Description |
---|---|
int |
getHeartbeatInterval()
Returns the number of seconds between heartbeat requests of a UI, or a
non-positive number if heartbeat is disabled.
|
int |
getMaxMessageSuspendTimeout()
In certain cases, such as when combining XmlHttpRequests and push over
low bandwidth connections, messages may be received out of order by the
client.
|
PushMode |
getPushMode()
Returns the mode of bidirectional ("push") client-server communication
that should be used.
|
String |
getPushURL()
Returns the URL that bidirectional ("push") client-server communication
should use.
|
int |
getWebComponentDisconnect()
Returns the number of seconds that a WebComponent will wait for a
reconnect before removing the server-side component from memory.
|
boolean |
isBowerMode()
Deprecated.
|
boolean |
isCloseIdleSessions()
Returns whether a Vaadin session should be closed when all its open UIs
have been idle for longer than its configured maximum inactivity time.
|
boolean |
isProductionMode()
Returns whether Vaadin is in production mode.
|
boolean |
isRequestTiming()
Returns whether the server provides timing info to the client.
|
boolean |
isSendUrlsAsParameters()
Returns whether the sending of URL's as GET and POST parameters in
requests with content-type
application/x-www-form-urlencoded
is enabled or not. |
boolean |
isSyncIdCheckEnabled()
Returns whether sync id checking is enabled.
|
boolean |
isXsrfProtectionEnabled()
Returns whether cross-site request forgery protection is enabled.
|
getApplicationOrSystemProperty, getApplicationProperty, getInitParameters, getSystemProperty, isCompatibilityMode
getClassLoaderName, getUIClassName
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
areWebJarsEnabled, disableAutomaticServletRegistration, enableDevServer, getBooleanProperty, getCompiledWebComponentsPath, getDevelopmentFrontendPrefix, getEs5FrontendPrefix, getEs6FrontendPrefix, getExternalStatsUrl, getNpmFrontendPrefix, getPolyfills, getStringProperty, isBrotli, isDevModeLiveReloadEnabled, isEnforcedFieldValidationEnabled, isOldLicenseCheckerEnabled, isPnpmEnabled, isStatsExternal, reuseDevServer, useCompiledFrontendResources
public static final String NOT_PRODUCTION_MODE_INFO
public static final String WARNING_COMPATIBILITY_MODE
public static final String WARNING_LIVERELOAD_DISABLED_AND_NEW_LICENSE_CHECKER
public static final String NOT_PRODUCTION_MODE_WARNING
public static final String WARNING_XSRF_PROTECTION_DISABLED
public static final String WARNING_HEARTBEAT_INTERVAL_NOT_NUMERIC
public static final String WARNING_PUSH_MODE_NOT_RECOGNIZED
public static final int DEFAULT_HEARTBEAT_INTERVAL
getHeartbeatInterval()
= 300 .public static final int DEFAULT_MAX_MESSAGE_SUSPEND_TIMEOUT
getMaxMessageSuspendTimeout()
()} = 5000 .public static final int DEFAULT_WEB_COMPONENT_DISCONNECT
getWebComponentDisconnect()
= 300.public static final boolean DEFAULT_CLOSE_IDLE_SESSIONS
isCloseIdleSessions()
= false .public static final boolean DEFAULT_SYNC_ID_CHECK
isSyncIdCheckEnabled()
= true .public static final boolean DEFAULT_SEND_URLS_AS_PARAMETERS
public DefaultDeploymentConfiguration(Class<?> systemPropertyBaseClass, Properties initParameters)
systemPropertyBaseClass
- the class that should be used as a basis when reading system
propertiesinitParameters
- the init parameters that should make up the foundation for
this configurationpublic boolean isProductionMode()
The default is false.
isProductionMode
in interface DeploymentConfiguration
isProductionMode
in class PropertyDeploymentConfiguration
@Deprecated public boolean isBowerMode()
isBowerMode
in interface DeploymentConfiguration
isBowerMode
in class PropertyDeploymentConfiguration
public boolean isRequestTiming()
The default is true
when not in production and
false
when in production mode.
isRequestTiming
in interface DeploymentConfiguration
isRequestTiming
in class PropertyDeploymentConfiguration
public boolean isXsrfProtectionEnabled()
The default is true.
isXsrfProtectionEnabled
in interface DeploymentConfiguration
isXsrfProtectionEnabled
in class PropertyDeploymentConfiguration
public int getHeartbeatInterval()
The default interval is 300 seconds (5 minutes).
getHeartbeatInterval
in interface DeploymentConfiguration
getHeartbeatInterval
in class PropertyDeploymentConfiguration
public int getMaxMessageSuspendTimeout()
The default max message suspension time is 5000 milliseconds.
getMaxMessageSuspendTimeout
in interface DeploymentConfiguration
getMaxMessageSuspendTimeout
in class PropertyDeploymentConfiguration
public int getWebComponentDisconnect()
DeploymentConfiguration
getWebComponentDisconnect
in interface DeploymentConfiguration
getWebComponentDisconnect
in class PropertyDeploymentConfiguration
public boolean isCloseIdleSessions()
A UI is idle if it is open on the client side but has no activity other
than heartbeat requests. If isCloseIdleSessions() == false
,
heartbeat requests cause the session to stay open for as long as there
are open UIs on the client side. If it is true
, the session is
eventually closed if the open UIs do not have any user interaction.
The default value is false.
isCloseIdleSessions
in interface DeploymentConfiguration
isCloseIdleSessions
in class PropertyDeploymentConfiguration
WrappedSession.getMaxInactiveInterval()
public boolean isSyncIdCheckEnabled()
The default value is true
.
isSyncIdCheckEnabled
in interface DeploymentConfiguration
isSyncIdCheckEnabled
in class PropertyDeploymentConfiguration
true
if sync id checking is enabled;
false
otherwisepublic boolean isSendUrlsAsParameters()
application/x-www-form-urlencoded
is enabled or not.
The default value is true
.
isSendUrlsAsParameters
in interface DeploymentConfiguration
isSendUrlsAsParameters
in class PropertyDeploymentConfiguration
false
if set to false or true
otherwisepublic PushMode getPushMode()
The default mode is PushMode.DISABLED
.
getPushMode
in interface DeploymentConfiguration
getPushMode
in class PropertyDeploymentConfiguration
public String getPushURL()
The default mode is ""
which uses the servlet URL.
getPushURL
in interface DeploymentConfiguration
getPushURL
in class PropertyDeploymentConfiguration
Copyright © 2025. All rights reserved.