Interface Configuration


  • public interface Configuration
    Provides the interface for various runtime configuration settings.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Interface Description
      static class  Configuration.ScheduledEventExecution
      Defines the options to control which scheduled events get executed.
    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods 
      Modifier and Type Method Description
      void checkConfig()
      Set default values for uninitialized fields if no custom configuration options were supplied, and feed them back again to updateConfiguration.
      default boolean enablePersistentSessions()
      Deprecated.
      since Mendix 9.
      java.lang.String getAdminUserName()
      Returns the name of the admin user.
      java.lang.String getAdminUserRoleName()
      Returns the name of the admin role.
      java.lang.String getApplicationRootUrl()
      Returns the server address that the run-time can be reached at.
      java.io.File getBasePath()
      Returns the location on the local file system of the project deployment (i.e.
      java.util.List<java.io.InputStream> getCACertificates()
      Returns all configured CA certificates.
      java.util.List<java.lang.String> getClientCertificatePasswords()
      Returns the password for all configured client certificates.
      java.util.List<java.io.InputStream> getClientCertificates()
      Returns all configured client certificates.
      java.lang.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.
      long getClusterManagerActionInterval()
      Returns the interval (in milliseconds) used for performing all cluster manager actions.
      int getClusterManagerQueryTimeout()
      Returns the cluster manager query timeout (in seconds).
      java.lang.Object getConstantValue​(java.lang.String key)
      Returns the value for the constant with the specified name.
      long getCSVExportBatchSize()
      Returns the batch size for CSV exports.
      boolean getEnableGuestLogin()
      Returns whether guest logins are enabled.
      java.lang.String getFileSeparator()
      Returns the file path separator, which is hardcoded to "/", so that forms can be exported on Windows and used on Linux.
      java.lang.String getGuestUserRoleName()
      Returns the role name for guest users.
      java.lang.String getIFrameUploadDomain()
      Returns the document domain name.
      java.io.File getImagePath()
      Returns the location in the local file system for images.
      java.lang.String getImageUrl()
      Returns the relative URL path for images.
      java.lang.String getJavaKeyStorePassword()
      Returns the password of the Java keystore.
      java.io.File getModelerFile()
      Returns the location on the local file system of the project file.
      java.io.File getMxClientSystemPath()
      Returns the location of the client files on the local filesystem.
      java.util.Set<java.lang.String> getMyScheduledEvents()
      Returns the (qualified) names of the scheduled events from the project.
      java.lang.String getNewLine()
      Returns the line separation character(s).
      java.util.Set<java.lang.String> getPublicConstants()
      Returns the names of all publicly defined constants.
      java.io.File getPublicWebrootPath()
      Returns the root location in the local file system for the public web server.
      java.io.File getResourcesPath()
      Returns the path to the resources folder; the default is model/resources.
      java.io.File getRuntimePath()
      Returns the location on the local file system of the runtime bundles.
      Configuration.ScheduledEventExecution getScheduledEventExecution()
      Returns which scheduled events should be executed (all, specified, none).
      java.lang.String getSessionIdCookieName()
      Returns the name of the HTTP header field for session cookies.
      long getSessionKeepAliveUpdatesInterval()
      Returns the interval (in milliseconds) used for performing keep alive updates on sessions.
      int getSessionTimeout()
      Returns after how much time a session becomes invalid (in milliseconds).
      int getSessionValidationTimeout()
      Returns the interval (in milliseconds) after which cached sessions need to be revalidated in the runtime server.
      java.lang.String getStorageService()
      Returns the name of the storage service module that is used.
      java.io.File getTempPath()
      Returns the path to the temporary files folder; the default is data/tmp.
      java.lang.String getXASId()
      Returns the identifier of this runtime server instance.
      boolean hasMicroflowConstantConfig​(java.lang.String key)
      Returns whether the microflow constants contain the specified name.
      boolean isFileDocumentCachingEnabled()
      Returns whether file document caching is enabled.
      boolean isInDevelopment()
      Returns whether this runtime server is running in development mode, which is determined from the DTAPMode custom runtime setting.
      boolean isKeepAliveEnabled()
      Returns whether the web client sends a keep alive request to prevent a session timeout.
      boolean isLocalFileSystemCleaningEnabled()
      Returns whether cleaning orphan files on the local file system is enabled.
      boolean shouldTrackWebServiceUserLastLogin()
      Returns whether to update the web service user’s LastLogin field on each login.
      void updateConfiguration​(java.util.Map<java.lang.String,​java.lang.Object> config, boolean overwrite)
      Updates the current configuration with the specified configuration settings.
    • Field Detail

      • RUNTIME_VERSION

        static final RuntimeVersion RUNTIME_VERSION
        Contains the version of the runtime server.
    • Method Detail

      • updateConfiguration

        void updateConfiguration​(java.util.Map<java.lang.String,​java.lang.Object> config,
                                 boolean overwrite)
        Updates the current configuration with the specified configuration settings.
        Parameters:
        config - the configuration settings to update
        overwrite - true if existing settings should be overwritten; false otherwise
      • checkConfig

        void checkConfig()
                  throws AdminException
        Set default values for uninitialized fields if no custom configuration options were supplied, and feed them back again to updateConfiguration.
        Throws:
        AdminException
      • getXASId

        java.lang.String getXASId()
        Returns the identifier of this runtime server instance.
      • getBasePath

        java.io.File getBasePath()
        Returns the location on the local file system of the project deployment (i.e. the deployment directory).
      • getFileSeparator

        java.lang.String getFileSeparator()
        Returns the file path separator, which is hardcoded to "/", so that forms can be exported on Windows and used on Linux.
      • getNewLine

        java.lang.String getNewLine()
        Returns the line separation character(s).
      • getPublicWebrootPath

        java.io.File getPublicWebrootPath()
        Returns the root location in the local file system for the public web server.
      • getImagePath

        java.io.File getImagePath()
        Returns the location in the local file system for images.
      • getResourcesPath

        java.io.File getResourcesPath()
        Returns the path to the resources folder; the default is model/resources.
      • getImageUrl

        java.lang.String getImageUrl()
        Returns the relative URL path for images.
      • getTempPath

        java.io.File getTempPath()
        Returns the path to the temporary files folder; the default is data/tmp.
      • getSessionKeepAliveUpdatesInterval

        long getSessionKeepAliveUpdatesInterval()
        Returns the interval (in milliseconds) used for performing keep alive updates on sessions.
      • getClusterManagerActionInterval

        long getClusterManagerActionInterval()
        Returns the interval (in milliseconds) used for performing all cluster manager actions.
      • getSessionTimeout

        int getSessionTimeout()
        Returns after how much time a session becomes invalid (in milliseconds).
      • getSessionValidationTimeout

        int getSessionValidationTimeout()
        Returns the interval (in milliseconds) after which cached sessions need to be revalidated in the runtime server.
      • isKeepAliveEnabled

        boolean isKeepAliveEnabled()
        Returns whether the web client sends a keep alive request to prevent a session timeout.
      • isFileDocumentCachingEnabled

        boolean isFileDocumentCachingEnabled()
        Returns whether file document caching is enabled.
      • getApplicationRootUrl

        java.lang.String getApplicationRootUrl()
        Returns the server address that the run-time can be reached at. This is used to generate WSDLs.
      • getIFrameUploadDomain

        java.lang.String getIFrameUploadDomain()
        Returns the document domain name.
      • getModelerFile

        java.io.File getModelerFile()
        Returns the location on the local file system of 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

        java.io.File getRuntimePath()
        Returns the location on the local file system of the runtime bundles.
      • getClientQueryTimeout

        java.lang.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.
      • getConstantValue

        java.lang.Object getConstantValue​(java.lang.String key)
        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

        java.util.Set<java.lang.String> getPublicConstants()
        Returns the names of all publicly defined constants.
        Returns:
        the names of the constants
      • getMyScheduledEvents

        java.util.Set<java.lang.String> getMyScheduledEvents()
        Returns the (qualified) names of the scheduled events from the project.
      • hasMicroflowConstantConfig

        boolean hasMicroflowConstantConfig​(java.lang.String key)
        Returns whether the microflow constants contain the specified name.
        Parameters:
        key - the name of the microflow constant
      • getAdminUserRoleName

        java.lang.String getAdminUserRoleName()
        Returns the name of the admin role.
      • getAdminUserName

        java.lang.String getAdminUserName()
        Returns the name of the admin user.
      • getEnableGuestLogin

        boolean getEnableGuestLogin()
        Returns whether guest logins are enabled.
      • getGuestUserRoleName

        java.lang.String getGuestUserRoleName()
        Returns the role name for guest users.
      • enablePersistentSessions

        @Deprecated
        default boolean enablePersistentSessions()
        Deprecated.
        since Mendix 9. Support for non-persistent sessions is removed. This method should not be used any more.
        This method always returns false.
      • getMxClientSystemPath

        java.io.File getMxClientSystemPath()
        Returns the location of the client files on the local filesystem.
      • getJavaKeyStorePassword

        java.lang.String getJavaKeyStorePassword()
        Returns the password of the Java keystore.
      • getCACertificates

        java.util.List<java.io.InputStream> getCACertificates()
                                                       throws java.io.IOException
        Returns all configured CA certificates.
        Throws:
        java.io.IOException
      • getClientCertificates

        java.util.List<java.io.InputStream> getClientCertificates()
                                                           throws java.io.IOException
        Returns all configured client certificates.
        Throws:
        java.io.IOException
      • getClientCertificatePasswords

        java.util.List<java.lang.String> getClientCertificatePasswords()
        Returns the password for all configured client certificates.
      • getCSVExportBatchSize

        long getCSVExportBatchSize()
        Returns the batch size for CSV exports.
      • shouldTrackWebServiceUserLastLogin

        boolean shouldTrackWebServiceUserLastLogin()
        Returns whether to update the web service user’s LastLogin field on each login.
      • getSessionIdCookieName

        java.lang.String getSessionIdCookieName()
        Returns the name of the HTTP header field for session cookies.
      • 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.
      • getStorageService

        java.lang.String getStorageService()
        Returns the name of the storage service module that is used.