Package com.evolveum.midpoint.init
Class StartupConfiguration
- java.lang.Object
 - 
- com.evolveum.midpoint.init.StartupConfiguration
 
 
- 
- All Implemented Interfaces:
 MidpointConfiguration
public class StartupConfiguration extends Object implements MidpointConfiguration
 
- 
- 
Field Summary
Fields Modifier and Type Field Description static StringDEFAULT_CONFIG_FILE_NAME- 
Fields inherited from interface com.evolveum.midpoint.common.configuration.api.MidpointConfiguration
AUDIT_CONFIGURATION, CONSTANTS_CONFIGURATION, DOT_CONFIGURATION, GLOBAL_CONFIGURATION, ICF_CONFIGURATION, INTERNALS_CONFIGURATION, MIDPOINT_CONFIG_FILE_PROPERTY, MIDPOINT_HOME_PROPERTY, MIDPOINT_HOST_NAME_PROPERTY, MIDPOINT_HTTP_PORT_PROPERTY, MIDPOINT_LOGGING_ALT_ENABLED_PROPERTY, MIDPOINT_LOGGING_ALT_FILENAME_PROPERTY, MIDPOINT_LOGGING_ALT_PREFIX_PROPERTY, MIDPOINT_NODE_ID_PROPERTY, MIDPOINT_NODE_ID_SOURCE_PROPERTY, MIDPOINT_SCHRODINGER_PROPERTY, MIDPOINT_SILENT_PROPERTY, MIDPOINT_SKIP_VERSION_CHECK, MIDPOINT_SYSTEM_PROPERTIES_BASE_PATH, MIDPOINT_URL_PROPERTY, PROTECTOR_CONFIGURATION, REPOSITORY_CONFIGURATION, ROOT_MIDPOINT_CONFIGURATION, SYSTEM_CONFIGURATION, TASK_MANAGER_CONFIGURATION, USER_HOME_PROPERTY, WEB_APP_CONFIGURATION, WORKFLOW_CONFIGURATION 
 - 
 
- 
Constructor Summary
Constructors Constructor Description StartupConfiguration(String midPointHome, String configFilename)Alternative constructor for use in the tests. 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetConfigFilename()Get current configuration file nameorg.apache.commons.configuration2.ConfigurationgetConfiguration()org.apache.commons.configuration2.ConfigurationgetConfiguration(@NotNull String componentName)Get configuration for symbolic name of the component from configuration subsystem.StringgetMidpointHome()@NotNull ProfilingModegetProfilingMode()@NotNull SystemConfigurationSectiongetSystemSection()voidinit()Initialize system configurationbooleanisProfilingEnabled()booleanisSafeMode()booleankeyMatches(String key, String... regexPatterns)Returns true if the configuration key matches any of provided regular expression patterns.StringtoString() 
 - 
 
- 
- 
Field Detail
- 
DEFAULT_CONFIG_FILE_NAME
public static final String DEFAULT_CONFIG_FILE_NAME
- See Also:
 - Constant Field Values
 
 
 - 
 
- 
Method Detail
- 
getConfigFilename
public String getConfigFilename()
Get current configuration file name 
- 
getMidpointHome
public String getMidpointHome()
- Specified by:
 getMidpointHomein interfaceMidpointConfiguration- Returns:
 - midPoint home directory. Currently it is the same value as in "midpoint.home" system property.
 
 
- 
getConfiguration
public org.apache.commons.configuration2.Configuration getConfiguration(@NotNull @NotNull String componentName)Description copied from interface:MidpointConfigurationGet configuration for symbolic name of the component from configuration subsystem.- Specified by:
 getConfigurationin interfaceMidpointConfiguration- Parameters:
 componentName- name of the component Samples of names:- repository -> midpoint.repository
 
- provisioning -> midpoint.provisioning
 
- Returns:
 - Configuration object
 Sample how to get config value: 
config.getInt("port", 1234); 
 
- 
getConfiguration
public org.apache.commons.configuration2.Configuration getConfiguration()
- Specified by:
 getConfigurationin interfaceMidpointConfiguration- Returns:
 - Global configuration.
 
 
- 
init
public void init()
Initialize system configuration 
- 
isSafeMode
public boolean isSafeMode()
- Specified by:
 isSafeModein interfaceMidpointConfiguration- Returns:
 - True if we are running in safe mode (the exact meaning gradually evolves; but the overall idea is to make midPoint barely usable to be able to fix the worst problems preventing it from running normally).
 
 
- 
isProfilingEnabled
public boolean isProfilingEnabled()
- Specified by:
 isProfilingEnabledin interfaceMidpointConfiguration- Returns:
 - True if the profiling interceptor should be loaded.
 
 
- 
getProfilingMode
@NotNull public @NotNull ProfilingMode getProfilingMode()
- Specified by:
 getProfilingModein interfaceMidpointConfiguration- Returns:
 - Current profiling mode e.g. on, off, dynamic.
 
 
- 
getSystemSection
@NotNull public @NotNull SystemConfigurationSection getSystemSection()
- Specified by:
 getSystemSectionin interfaceMidpointConfiguration- Returns:
 - "midpoint.system" section of the system configuration
 
 
- 
keyMatches
public boolean keyMatches(String key, String... regexPatterns)
Description copied from interface:MidpointConfigurationReturns true if the configuration key matches any of provided regular expression patterns. Provided pattern must match the whole value, seeString.matches(java.lang.String). Some examples:x\.y.*- value starts withx.y(dot must be escaped, in Java String syntax double backslash must be used!)(?i)sql- value is exactly SQL, ignoring casing
- Specified by:
 keyMatchesin interfaceMidpointConfiguration- Parameters:
 key- key from configuration, starting atconfigurationelement (root), can be complex, e.g.midpoint.repository.type.regexPatterns- regular expression patterns that must match the whole value. It is possible to matchnulltoo, if no regex pattern is used, or if the first pattern itself is null.
 
 - 
 
 -