Package com.mendix.core.conf
Interface Configuration
public interface Configuration
Provides the interface for various runtime configuration settings.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic enum
Defines the options to control which scheduled events get executed. -
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Deprecated.since 10.18.Returns the name of the admin user.Returns the name of the admin role.Returns the server address that the run-time can be reached at.Returns the location on the local file system of the project deployment.Returns all configured CA certificates.Returns the password for all configured client certificates.Returns all configured client certificates.Returns the timeout in seconds for most of the database queries which are executed to load data into client widgets, like data grids.long
Returns the interval (in milliseconds) used for performing all cluster manager actions.int
Returns the cluster manager query timeout (in seconds).Returns the names of all defined constants.getConstantValue
(String key) Returns the value for the constant with the specified name.long
Returns the batch size for CSV exports.Returns the value of the database setting as a string.boolean
Returns whether guest logins are enabled.Returns the file path separator, which is hardcoded to "/", so that forms can be exported on Windows and used on Linux.Returns the role name for guest users.Returns the document domain name.Returns the location in the local file system for images.Returns the relative URL path for images.Returns the password of the Java keystore.Returns the location on the local file system of the project file.Returns the location of the client files on the local filesystem.Returns the (qualified) names of the scheduled events from the project.Returns the line separation character(s).Returns the names of all publicly defined constants.Returns the root location in the local file system for the public web server.Returns the path to the resources folder; the default is model/resources.Returns the location on the local file system of the runtime bundles.Returns which scheduled events should be executed (all, specified, none).Returns the name of the HTTP header field for session cookies.long
Returns the interval (in milliseconds) used for performing keep-alive updates on sessions.int
Returns after how much time a session becomes invalid (in milliseconds).int
Returns the interval (in milliseconds) after which cached sessions need to be revalidated in the runtime server.Returns the name of the storage service module that is used.Returns the path to the temporary files folder; the default is data/tmp.getXASId()
Returns the identifier of this runtime server instance.boolean
Returns whether the microflow constants contain the specified name.boolean
Returns whether file document caching is enabled.boolean
Returns whether this runtime server is running in development mode, which is determined from the DTAPMode custom runtime setting.boolean
Returns whether the web client sends a keep-alive request to prevent a session timeout.boolean
Returns whether cleaning orphan files on the local file system is enabled.boolean
Returns whether change hashes are verified in a strict mode.boolean
Returns whether to update the web service user's LastLogin field on each login.void
updateConfiguration
(Map<String, Object> config, boolean overwrite) Updates the current configuration with the specified configuration settings.
-
Field Details
-
RUNTIME_VERSION
Deprecated.since 9.24. UseCore.getRuntimeVersion()
instead.Contains the version of the runtime server.
-
-
Method Details
-
updateConfiguration
Updates the current configuration with the specified configuration settings.- Parameters:
config
- the configuration settings to updateoverwrite
- true if existing settings should be overwritten; false otherwise
-
checkConfig
Deprecated.since 10.18. This method will be removed in Mendix 11. There is no replacement.Set default values for uninitialized fields if no custom configuration options were supplied, and feed them back again to updateConfiguration.- Throws:
AdminException
-
getXASId
String getXASId()Returns the identifier of this runtime server instance.- Returns:
- the runtime server instance identifier
-
getBasePath
File getBasePath()Returns the location on the local file system of the project deployment.- Returns:
- the deployment folder
-
getFileSeparator
String getFileSeparator()Returns the file path separator, which is hardcoded to "/", so that forms can be exported on Windows and used on Linux.- Returns:
- the file path separator
-
getNewLine
String getNewLine()Returns the line separation character(s).- Returns:
- the new line character(s)
-
getPublicWebrootPath
File getPublicWebrootPath()Returns the root location in the local file system for the public web server.- Returns:
- the web root folder
-
getImagePath
File getImagePath()Returns the location in the local file system for images.- Returns:
- the images folder
-
getResourcesPath
File getResourcesPath()Returns the path to the resources folder; the default is model/resources.- Returns:
- the resources folder
-
getImageUrl
String getImageUrl()Returns the relative URL path for images.- Returns:
- the relative image URL
-
getTempPath
File getTempPath()Returns the path to the temporary files folder; the default is data/tmp.- Returns:
- the temporary files folder
-
getSessionKeepAliveUpdatesInterval
long getSessionKeepAliveUpdatesInterval()Returns the interval (in milliseconds) used for performing keep-alive updates on sessions.- Returns:
- the update interval for session keep-alive
-
getClusterManagerActionInterval
long getClusterManagerActionInterval()Returns the interval (in milliseconds) used for performing all cluster manager actions.- Returns:
- the interval for cluster management
-
getSessionTimeout
int getSessionTimeout()Returns after how much time a session becomes invalid (in milliseconds).- Returns:
- the session timeout interval
-
getSessionValidationTimeout
int getSessionValidationTimeout()Returns the interval (in milliseconds) after which cached sessions need to be revalidated in the runtime server.- Returns:
- the interval for session validation
-
isKeepAliveEnabled
boolean isKeepAliveEnabled()Returns whether the web client sends a keep-alive request to prevent a session timeout.- Returns:
- true if keep-alive request must be sent by the web client, false otherwise
-
isFileDocumentCachingEnabled
boolean isFileDocumentCachingEnabled()Returns whether file document caching is enabled.- Returns:
- true if file document caching is enabled, false if it is disabled
-
isStrictChangeHashVerificationEnabled
boolean isStrictChangeHashVerificationEnabled()Returns whether change hashes are verified in a strict mode.- Returns:
- true if change hashed are verified, false otherwise
-
getApplicationRootUrl
String getApplicationRootUrl()Returns the server address that the run-time can be reached at. This is used to generate WSDLs.- Returns:
- the root URL of the application
-
getIFrameUploadDomain
String getIFrameUploadDomain()Returns the document domain name.- Returns:
- the domain name
-
getModelerFile
File getModelerFile()Returns the location on the local file system of the project file.- Returns:
- the project file
-
isInDevelopment
boolean isInDevelopment()Returns whether this runtime server is running in development mode, which is determined from the DTAPMode custom runtime setting.- Returns:
- true if the DTAPMode is development or testing, false otherwise
-
getRuntimePath
File getRuntimePath()Returns the location on the local file system of the runtime bundles.- Returns:
- the runtime bundles folder
-
getClientQueryTimeout
Integer getClientQueryTimeout()Returns the timeout in seconds for most of the database queries which are executed to load data into client widgets, like data grids.- Returns:
- the timeout for client queries
-
getConstantValue
Returns the value for the constant with the specified name.- Parameters:
key
- the name of the constant- Returns:
- the value of the constant if it exists
- Throws:
MendixRuntimeException
- if the constant does not exist
-
getPublicConstants
Returns the names of all publicly defined constants.- Returns:
- the names of the constants
-
getConstants
Returns the names of all defined constants.- Returns:
- the names of the constants
-
getScheduledEventExecution
Configuration.ScheduledEventExecution getScheduledEventExecution()Returns which scheduled events should be executed (all, specified, none).- Returns:
- the enum identifying which scheduled events to execute
-
getMyScheduledEvents
Returns the (qualified) names of the scheduled events from the project.- Returns:
- the set of scheduled events to execute,
if
getScheduledEventExecution()
is set toConfiguration.ScheduledEventExecution.SPECIFIED
-
hasMicroflowConstantConfig
Returns whether the microflow constants contain the specified name.- Parameters:
key
- the name of the microflow constant- Returns:
- true if the specified constant exists, false otherwise
-
getAdminUserRoleName
String getAdminUserRoleName()Returns the name of the admin role.- Returns:
- the role name of the admin user
-
getAdminUserName
String getAdminUserName()Returns the name of the admin user.- Returns:
- the name of the admin user
-
getEnableGuestLogin
boolean getEnableGuestLogin()Returns whether guest logins are enabled.- Returns:
- true if guest logins are enabled, false if they are disabled
-
getGuestUserRoleName
String getGuestUserRoleName()Returns the role name for guest users.- Returns:
- the role name of a guest user
-
getMxClientSystemPath
File getMxClientSystemPath()Returns the location of the client files on the local filesystem.- Returns:
- the client files folder
-
getJavaKeyStorePassword
String getJavaKeyStorePassword()Returns the password of the Java keystore.- Returns:
- the Java keystore password
-
getCACertificates
Returns all configured CA certificates.- Returns:
- the CA certificates
- Throws:
IOException
-
getClientCertificates
Returns all configured client certificates.- Returns:
- the client certificates
- Throws:
IOException
-
getClientCertificatePasswords
Returns the password for all configured client certificates.- Returns:
- the client certificate passwords
-
getCSVExportBatchSize
long getCSVExportBatchSize()Returns the batch size for CSV exports.- Returns:
- the batch size
-
shouldTrackWebServiceUserLastLogin
boolean shouldTrackWebServiceUserLastLogin()Returns whether to update the web service user's LastLogin field on each login.- Returns:
- true if the web-service user should be updated, false otherwise
-
getSessionIdCookieName
String getSessionIdCookieName()Returns the name of the HTTP header field for session cookies.- Returns:
- the header name of the session cookie
-
getClusterManagerQueryTimeout
int getClusterManagerQueryTimeout()Returns the cluster manager query timeout (in seconds).- Returns:
- the timeout in seconds
-
isLocalFileSystemCleaningEnabled
boolean isLocalFileSystemCleaningEnabled()Returns whether cleaning orphan files on the local file system is enabled.- Returns:
- true if file system cleanup is enabled, false if it is disabled
-
getStorageService
String getStorageService()Returns the name of the storage service module that is used.- Returns:
- the name of the current storage module
-
getDatabaseSettingAsString
Returns the value of the database setting as a string.- Parameters:
name
- the name of the setting- Returns:
- the value of the setting with the given name
-