public class SettingsBean extends Object implements org.springframework.web.context.ServletContextAware, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware, ReadOnlyModeCapable, SettingsBean
| Modifier and Type | Field and Description |
|---|---|
static String |
JAHIA_BACKUP_RESTORE_SYSTEM_PROP
Deprecated.
Use
isStartupOptionSet(String) instead |
static String |
JAHIA_PROPERTIES_FILE_PATH |
| Constructor and Description |
|---|
SettingsBean(PathResolver pathResolver,
Properties props,
List<String> licenseFileLocations) |
SettingsBean(PathResolver pathResolver,
String propertiesFilename,
String licenseFilename,
String buildNumber) |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
static String |
convertContexted(String convert,
PathResolver pathResolver)
Convert a String starting with the word "$context" into a real filesystem
path.
|
static String |
convertWebContexted(String convert)
Convert a string starting with the word "$webContext" into a real
filesystem path.
|
int |
getAccessManagerPathPermissionCacheMaxSize() |
org.springframework.context.ApplicationContext |
getApplicationContext() |
String |
getAtmosphereAsyncSupport() |
String |
getAtmosphereHeartbeatFrequency() |
String[] |
getAuthorizedRedirectHosts() |
boolean |
getBoolean(String propertyName,
boolean defaultValue) |
String |
getBuildNumber()
Used to get the build number.
|
String |
getCharacterEncoding() |
String |
getClassDiskPath() |
CookieAuthConfig |
getCookieAuthConfig() |
String |
getDefaultLanguageCode() |
Locale |
getDefaultLocale() |
static File |
getErrorDir()
Returns the directory where the automatic error reports are generated by Jahia.
|
String |
getExpandImportedFilesOnDiskPath() |
int |
getFileDumpMaxRegroupingOfPreviousException() |
String |
getGuestGroupResourceKey() |
String |
getGuestGroupResourceModuleName() |
String |
getGuestUserResourceKey() |
String |
getGuestUserResourceModuleName() |
static File |
getHeapDir()
Returns the directory where the triggered heap dumps are generated by Digital Experience Manager.
|
int |
getImportMaxBatch() |
static SettingsBean |
getInstance() |
int |
getInt(String propertyName,
int defaultValue) |
String |
getInternetExplorerCompatibility() |
String |
getJahiaDatabaseScriptsPath() |
String |
getJahiaEtcDiskPath()
Used to get the jahiafiles /etc disk path.
|
String |
getJahiaExportsDiskPath() |
long |
getJahiaFileUploadMaxSize() |
String |
getJahiaGeneratedResourcesDiskPath() |
String |
getJahiaHomeDiskPath()
Deprecated.
since 7.0.0.2
|
String |
getJahiaImportsDiskPath() |
long |
getJahiaJCRUserCountLimit() |
String |
getJahiaModulesDiskPath()
Used to get the shared templates disk path.
|
int |
getJahiaSiteImportScannerInterval() |
String |
getJahiaVarDiskPath()
Used to get the jahiafiles /var disk path.
|
String |
getJahiaWebAppsDeployerBaseURL() |
String |
getJsessionIdParameterName() |
org.springframework.core.io.Resource |
getLicenseFile() |
String |
getLicenseFileName() |
long |
getLong(String propertyName,
long defaultValue) |
int |
getMail_maxRegroupingOfPreviousException() |
int |
getMaxNameSize() |
int |
getModuleSpringBeansWaitingTimeout() |
String |
getModulesSourcesDiskPath() |
int |
getModuleStartLevel() |
String |
getOperatingMode() |
PathResolver |
getPathResolver() |
Properties |
getPropertiesFile()
Get the principal properties object.
|
String |
getPropertyValue(String propertyName) |
int |
getQueryApproxCountLimit() |
int |
getReadOnlyModePriority()
Get the priority of the service.
|
File |
getRepositoryHome() |
org.springframework.core.io.Resource |
getRepositoryHomeResource() |
String |
getServer()
Used to get the server name (tomcat, orion, etc).
|
org.jahia.configuration.deployers.ServerDeploymentInterface |
getServerDeployer() |
String |
getServerHome()
Used to get the server home filesystem disk path.
|
String |
getServerVersion() |
javax.servlet.ServletContext |
getServletContext() |
int |
getSessionExpiryTime() |
boolean |
getSiteErrorEnabled()
to get the Site errors page behavior
|
int |
getSiteURLPortOverride() |
StartupOptions |
getStartupOptions()
Returns the startup options, which are set.
|
String |
getString(String propertyName) |
String |
getString(String propertyName,
String defaultValue) |
long |
getStudioMaxDisplayableFileSize() |
String |
getTemplatesContext()
Used to get the templates context.
|
static File |
getThreadDir()
Returns the directory where the automatic or triggered thread dumps are generated by Jahia.
|
String |
getTmpContentDiskPath() |
void |
initPaths() |
boolean |
isAreaAutoActivated() |
boolean |
isClusterActivated()
Returns
true if the clustering is activated. |
boolean |
isConsiderDefaultJVMLocale() |
boolean |
isConsiderPreferredLanguageAfterLogin() |
boolean |
isDevelopmentMode() |
boolean |
isDisableJsessionIdParameter() |
boolean |
isDistantPublicationServerMode() |
boolean |
isDumpErrorsToFiles() |
boolean |
isExpandImportedFilesOnDisk() |
boolean |
isFileServletStatisticsEnabled() |
boolean |
isFullReadOnlyMode()
Returns
true if this Jahia instance operates in "full-read-only" mode, i.e. |
boolean |
isMaintenanceMode() |
boolean |
isMavenExecutableSet() |
boolean |
isPermanentMoveForVanityURL() |
boolean |
isProcessingServer() |
boolean |
isProductionMode() |
boolean |
isReadOnlyMode()
Returns
true if this Jahia instance operates in "read-only" mode, i.e. |
boolean |
isStartupOptionSet(String option)
Checks if the specified startup option is set.
|
boolean |
isUrlRewriteRemoveCmsPrefix() |
boolean |
isUrlRewriteSeoRulesEnabled() |
boolean |
isUrlRewriteUseAbsoluteUrls() |
boolean |
isUseJstackForThreadDumps() |
boolean |
isUseRelativeSiteURLs()
Activation / deactivation of relative URLs, instead of absolute URLs, when generating URL to exit the Admin Menu for example
|
boolean |
isUseWebsockets() |
void |
load()
This method load and convert properties from the jahia.properties file,
and set some variables used by the SettingsBean class.
|
boolean |
lookupBoolean(String key)
Looks up the specified
key parameter as a boolean result. |
int |
lookupInt(String key)
Looks up the specified
key parameter as a long result. |
long |
lookupLong(String key)
Looks up the specified
key parameter as a long result. |
String |
lookupString(String key)
Looks up the specified
key parameter as a String result. |
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext) |
void |
setAtmosphereAsyncSupport(String atmosphereAsyncSupport) |
void |
setBuildNumber(String buildNumber) |
void |
setClusterSettingsInitializer(ClusterSettingsInitializer clusterSettingsInitializer) |
void |
setConsiderDefaultJVMLocale(boolean considerDefaultJVMLocale) |
void |
setConsiderPreferredLanguageAfterLogin(boolean considerPreferredLanguageAfterLogin) |
void |
setCookieAuthConfig(CookieAuthConfig cookieAuthConfig) |
void |
setDataSource(DataSource dataSource) |
void |
setDisableJsessionIdParameter(boolean disableJsessionIdParameter) |
void |
setDumpErrorsToFiles(boolean dumpErrorsToFiles) |
void |
setGuestGroupResourceKey(String guestGroupResourceKey) |
void |
setGuestGroupResourceModuleName(String guestGroupResourceModuleName) |
void |
setJahiaJCRUserCountLimit(long jahiaJCRUserCountLimit) |
void |
setJsessionIdParameterName(String jsessionIdParameterName) |
void |
setLicenseFile(org.springframework.core.io.Resource licenseFile) |
void |
setMail_maxRegroupingOfPreviousException(int mail_maxRegroupingOfPreviousException) |
void |
setMavenExecutableSet(boolean isMavenExecutableSet) |
void |
setModuleSpringBeansWaitingTimeout(int moduleSpringBeansWaitingTimeout) |
void |
setPathResolver(PathResolver pathResolver) |
void |
setReadOnlyMode(boolean readOnlyMode)
If set to
true, access to the edit/studio/administration modes is disabled on this Jahia instance. |
void |
setServletContext(javax.servlet.ServletContext servletContext) |
void |
setSessionExpiryTime(int sessionExpiryTime) |
void |
setSiteURLPortOverride(int siteURLPortOverride) |
void |
setStartupOptionsMapping(Map<String,Set<String>> startupOptionsMapping) |
void |
setUseRelativeSiteURLs(boolean val) |
void |
setUseWebsockets(boolean useWebsockets) |
void |
switchReadOnlyMode(boolean enable)
Enable/disable read-only mode for a specific functional area this ReadOnlyModeCapable is responsible for.
|
public static final String JAHIA_PROPERTIES_FILE_PATH
@Deprecated public static final String JAHIA_BACKUP_RESTORE_SYSTEM_PROP
isStartupOptionSet(String) insteadpublic SettingsBean(PathResolver pathResolver, String propertiesFilename, String licenseFilename, String buildNumber)
pathResolver - a path resolver used to locate files on the disk.propertiesFilename - The jahia.properties file complete path.licenseFilename - the name of the license file.buildNumber - The Jahia build number.public SettingsBean(PathResolver pathResolver, Properties props, List<String> licenseFileLocations)
public static SettingsBean getInstance()
public static File getErrorDir()
public static File getThreadDir()
public static File getHeapDir()
public String getJahiaDatabaseScriptsPath()
getJahiaDatabaseScriptsPath in interface SettingsBeanpublic long getJahiaJCRUserCountLimit()
getJahiaJCRUserCountLimit in interface SettingsBeanpublic String getAtmosphereHeartbeatFrequency()
public void setJahiaJCRUserCountLimit(long jahiaJCRUserCountLimit)
public void load()
load in interface SettingsBeanpublic int getModuleStartLevel()
getModuleStartLevel in interface SettingsBeanpublic void initPaths()
public boolean isClusterActivated()
true if the clustering is activated.isClusterActivated in interface SettingsBeantrue if the clustering is activated; false otherwisepublic File getRepositoryHome() throws IOException
getRepositoryHome in interface SettingsBeanIOExceptionpublic org.springframework.core.io.Resource getRepositoryHomeResource()
throws IOException
IOExceptionpublic Locale getDefaultLocale()
getDefaultLocale in interface SettingsBeanpublic boolean getBoolean(String propertyName, boolean defaultValue)
getBoolean in interface SettingsBeanpublic String getString(String propertyName) throws NoSuchElementException
getString in interface SettingsBeanNoSuchElementExceptionpublic String getString(String propertyName, String defaultValue)
getString in interface SettingsBeanpublic int getInt(String propertyName, int defaultValue)
getInt in interface SettingsBeanpublic long getLong(String propertyName, long defaultValue)
getLong in interface SettingsBeanpublic String getPropertyValue(String propertyName)
getPropertyValue in interface SettingsBeanpublic String lookupString(String key)
key parameter as a String result.lookupString in interface SettingsBeankey - the parameter key to lookupnull when the
parameter could not be found.public boolean lookupBoolean(String key)
key parameter as a boolean result.lookupBoolean in interface SettingsBeankey - the parameter key to lookupfalse when the
parameter could not be found.public long lookupLong(String key)
key parameter as a long result.lookupLong in interface SettingsBeankey - the parameter key to lookupLong.MIN_VALUE when the
parameter could not be found.public int lookupInt(String key)
key parameter as a long result.lookupInt in interface SettingsBeankey - the parameter key to lookupLong.MIN_VALUE when the
parameter could not be found.public Properties getPropertiesFile()
getPropertiesFile in interface SettingsBeanpublic String getLicenseFileName()
getLicenseFileName in interface SettingsBeanpublic boolean isUseRelativeSiteURLs()
isUseRelativeSiteURLs in interface SettingsBeanpublic void setUseRelativeSiteURLs(boolean val)
public String getJahiaWebAppsDeployerBaseURL()
getJahiaWebAppsDeployerBaseURL in interface SettingsBeanpublic String getDefaultLanguageCode()
getDefaultLanguageCode in interface SettingsBeanpublic String getBuildNumber()
getBuildNumber in interface SettingsBeanpublic void setBuildNumber(String buildNumber)
public String getServer()
getServer in interface SettingsBeanpublic String getServerHome()
getServerHome in interface SettingsBeanpublic String getJahiaEtcDiskPath()
getJahiaEtcDiskPath in interface SettingsBeanpublic String getJahiaVarDiskPath()
getJahiaVarDiskPath in interface SettingsBeanpublic String getJahiaModulesDiskPath()
getJahiaModulesDiskPath in interface SettingsBeanpublic String getJahiaGeneratedResourcesDiskPath()
getJahiaGeneratedResourcesDiskPath in interface SettingsBeanpublic String getClassDiskPath()
getClassDiskPath in interface SettingsBeanpublic long getJahiaFileUploadMaxSize()
getJahiaFileUploadMaxSize in interface SettingsBean@Deprecated public String getJahiaHomeDiskPath()
getJahiaHomeDiskPath in interface SettingsBeanpublic String getJahiaImportsDiskPath()
getJahiaImportsDiskPath in interface SettingsBeanpublic String getJahiaExportsDiskPath()
getJahiaExportsDiskPath in interface SettingsBeanpublic String getCharacterEncoding()
getCharacterEncoding in interface SettingsBeanpublic PathResolver getPathResolver()
public void setPathResolver(PathResolver pathResolver)
public String getTmpContentDiskPath()
getTmpContentDiskPath in interface SettingsBeanpublic String getModulesSourcesDiskPath()
getModulesSourcesDiskPath in interface SettingsBeanpublic boolean isProcessingServer()
isProcessingServer in interface SettingsBeanpublic int getSiteURLPortOverride()
getSiteURLPortOverride in interface SettingsBeanpublic void setSiteURLPortOverride(int siteURLPortOverride)
setSiteURLPortOverride in interface SettingsBeanpublic int getMail_maxRegroupingOfPreviousException()
public void setMail_maxRegroupingOfPreviousException(int mail_maxRegroupingOfPreviousException)
public boolean isDevelopmentMode()
isDevelopmentMode in interface SettingsBeanpublic boolean getSiteErrorEnabled()
getSiteErrorEnabled in interface SettingsBeanpublic boolean isConsiderDefaultJVMLocale()
isConsiderDefaultJVMLocale in interface SettingsBeanpublic void setConsiderDefaultJVMLocale(boolean considerDefaultJVMLocale)
public boolean isConsiderPreferredLanguageAfterLogin()
isConsiderPreferredLanguageAfterLogin in interface SettingsBeanpublic void setConsiderPreferredLanguageAfterLogin(boolean considerPreferredLanguageAfterLogin)
public boolean isPermanentMoveForVanityURL()
isPermanentMoveForVanityURL in interface SettingsBeanpublic boolean isDumpErrorsToFiles()
isDumpErrorsToFiles in interface SettingsBeanpublic void setDumpErrorsToFiles(boolean dumpErrorsToFiles)
public int getFileDumpMaxRegroupingOfPreviousException()
getFileDumpMaxRegroupingOfPreviousException in interface SettingsBeanpublic String getServerVersion()
getServerVersion in interface SettingsBeanpublic org.jahia.configuration.deployers.ServerDeploymentInterface getServerDeployer()
getServerDeployer in interface SettingsBeanpublic boolean isMaintenanceMode()
isMaintenanceMode in interface SettingsBeanpublic int getSessionExpiryTime()
getSessionExpiryTime in interface SettingsBeanpublic void setSessionExpiryTime(int sessionExpiryTime)
public boolean isDisableJsessionIdParameter()
isDisableJsessionIdParameter in interface SettingsBeanpublic void setDisableJsessionIdParameter(boolean disableJsessionIdParameter)
public String getJsessionIdParameterName()
getJsessionIdParameterName in interface SettingsBeanpublic void setJsessionIdParameterName(String jsessionIdParameterName)
public String getGuestUserResourceKey()
getGuestUserResourceKey in interface SettingsBeanpublic String getGuestUserResourceModuleName()
getGuestUserResourceModuleName in interface SettingsBeanpublic String getGuestGroupResourceModuleName()
getGuestGroupResourceModuleName in interface SettingsBeanpublic void setGuestGroupResourceModuleName(String guestGroupResourceModuleName)
public String getGuestGroupResourceKey()
getGuestGroupResourceKey in interface SettingsBeanpublic void setGuestGroupResourceKey(String guestGroupResourceKey)
public static String convertContexted(String convert, PathResolver pathResolver)
convert - The string to convert.pathResolver - The path resolver used to get the real path.public static String convertWebContexted(String convert)
convert - the string to convertpublic void setServletContext(javax.servlet.ServletContext servletContext)
setServletContext in interface org.springframework.web.context.ServletContextAwarepublic javax.servlet.ServletContext getServletContext()
public String getTemplatesContext()
getTemplatesContext in interface SettingsBeanpublic org.springframework.core.io.Resource getLicenseFile()
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
throws org.springframework.beans.BeansException
setApplicationContext in interface org.springframework.context.ApplicationContextAwareorg.springframework.beans.BeansExceptionpublic org.springframework.context.ApplicationContext getApplicationContext()
public void afterPropertiesSet()
throws Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanExceptionpublic void switchReadOnlyMode(boolean enable)
ReadOnlyModeCapableswitchReadOnlyMode in interface SettingsBeanswitchReadOnlyMode in interface ReadOnlyModeCapableenable - true in case the read-only mode should be enabled; false otherwisepublic int getReadOnlyModePriority()
ReadOnlyModeCapablegetReadOnlyModePriority in interface SettingsBeangetReadOnlyModePriority in interface ReadOnlyModeCapablepublic String getOperatingMode()
getOperatingMode in interface SettingsBeanpublic boolean isProductionMode()
isProductionMode in interface SettingsBeanpublic boolean isDistantPublicationServerMode()
isDistantPublicationServerMode in interface SettingsBeanpublic boolean isUseJstackForThreadDumps()
isUseJstackForThreadDumps in interface SettingsBeanpublic boolean isUrlRewriteSeoRulesEnabled()
isUrlRewriteSeoRulesEnabled in interface SettingsBeanpublic boolean isFileServletStatisticsEnabled()
isFileServletStatisticsEnabled in interface SettingsBeanpublic boolean isUrlRewriteUseAbsoluteUrls()
isUrlRewriteUseAbsoluteUrls in interface SettingsBeanpublic boolean isUrlRewriteRemoveCmsPrefix()
isUrlRewriteRemoveCmsPrefix in interface SettingsBeanpublic int getImportMaxBatch()
getImportMaxBatch in interface SettingsBeanpublic int getMaxNameSize()
getMaxNameSize in interface SettingsBeanpublic boolean isExpandImportedFilesOnDisk()
isExpandImportedFilesOnDisk in interface SettingsBeanpublic String getExpandImportedFilesOnDiskPath()
getExpandImportedFilesOnDiskPath in interface SettingsBeanpublic int getAccessManagerPathPermissionCacheMaxSize()
getAccessManagerPathPermissionCacheMaxSize in interface SettingsBeanpublic int getQueryApproxCountLimit()
getQueryApproxCountLimit in interface SettingsBeanpublic boolean isReadOnlyMode()
true if this Jahia instance operates in "read-only" mode, i.e. access to the edit/studio/administration modes is
not allowed.isReadOnlyMode in interface SettingsBeantrue if this Jahia instance operates in "read-only" mode, i.e. access to the edit/studio/administration modes is
not allowed; otherwise returns falsepublic boolean isFullReadOnlyMode()
true if this Jahia instance operates in "full-read-only" mode, i.e. access to the edit/studio/administration modes and
saving in the JCR are not allowed.isFullReadOnlyMode in interface SettingsBeantrue if this Jahia instance operates in "read-only" mode, i.e. access to the edit/studio/administration modes and
saving in the JCR are not allowed.; otherwise returns falsepublic void setReadOnlyMode(boolean readOnlyMode)
true, access to the edit/studio/administration modes is disabled on this Jahia instance.readOnlyMode - set to true to disable access to the edit/studio/administration modes on this Jahia instancepublic void setDataSource(DataSource dataSource)
public void setClusterSettingsInitializer(ClusterSettingsInitializer clusterSettingsInitializer)
public String getInternetExplorerCompatibility()
getInternetExplorerCompatibility in interface SettingsBeanpublic boolean isMavenExecutableSet()
isMavenExecutableSet in interface SettingsBeanpublic void setMavenExecutableSet(boolean isMavenExecutableSet)
public String[] getAuthorizedRedirectHosts()
getAuthorizedRedirectHosts in interface SettingsBeanpublic boolean isUseWebsockets()
isUseWebsockets in interface SettingsBeanpublic void setUseWebsockets(boolean useWebsockets)
public String getAtmosphereAsyncSupport()
getAtmosphereAsyncSupport in interface SettingsBeanpublic void setAtmosphereAsyncSupport(String atmosphereAsyncSupport)
public boolean isAreaAutoActivated()
isAreaAutoActivated in interface SettingsBeanpublic int getModuleSpringBeansWaitingTimeout()
getModuleSpringBeansWaitingTimeout in interface SettingsBeanpublic void setModuleSpringBeansWaitingTimeout(int moduleSpringBeansWaitingTimeout)
public void setLicenseFile(org.springframework.core.io.Resource licenseFile)
public StartupOptions getStartupOptions()
getStartupOptions in interface SettingsBeanpublic boolean isStartupOptionSet(String option)
isStartupOptionSet in interface SettingsBeanoption - the option keytrue if the specified option is set; false otherwisepublic void setStartupOptionsMapping(Map<String,Set<String>> startupOptionsMapping)
public int getJahiaSiteImportScannerInterval()
getJahiaSiteImportScannerInterval in interface SettingsBeanpublic long getStudioMaxDisplayableFileSize()
getStudioMaxDisplayableFileSize in interface SettingsBeanpublic CookieAuthConfig getCookieAuthConfig()
getCookieAuthConfig in interface SettingsBeanpublic void setCookieAuthConfig(CookieAuthConfig cookieAuthConfig)
Copyright © 2004–2021 Jahia Solutions Group SA. All rights reserved.