Interface JournalConfig
- All Superinterfaces:
Config
By default the journal service is not enabled. Enabling the journal will cause actions to be logged according to those selected in the journal configuration file within the selected configuration directory.
The journal can be used to log the use of various actions within the Diffusion server, but there is a processing cost so this should be used sparingly.
- Since:
- 6.12
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionGets the journal configuration directory.Returns the name of the journal configuration file.Returns the list specifying the session properties to be logged.boolean
Indicates whether the journal service is enabled.void
setConfigDirectory
(String directory) Sets the path of the directory holding the journal configuration file.void
setConfigFile
(String fileName) Sets the name of the configuration file within the indicated configuration directory.void
setEnabled
(boolean enabled) Enable or disable the journal service.void
setSessionProperties
(List<String> sessionProperties) Sets the session properties that should be logged with journal entries that relate to client sessions.
-
Field Details
-
DEFAULT_CONFIG_DIRECTORY
Default configuration directory.- See Also:
-
DEFAULT_CONFIG_FILE
Default configuration file name.- See Also:
-
-
Method Details
-
setEnabled
Enable or disable the journal service.The service is disabled by default.
- Parameters:
enabled
- true to enable the journal service- Throws:
ConfigException
- if the configuration islocked
-
isEnabled
boolean isEnabled()Indicates whether the journal service is enabled.- Returns:
- true if enabled
- See Also:
-
setConfigDirectory
Sets the path of the directory holding the journal configuration file.If not set, the default is
DEFAULT_CONFIG_DIRECTORY
.If the path is relative, it is evaluated relative to the Diffusion installation directory.
- Parameters:
directory
- the journal configuration directory- Throws:
ConfigException
- if unable to set the directory
-
getConfigDirectory
String getConfigDirectory()Gets the journal configuration directory.- Returns:
- journal configuration directory
-
setConfigFile
Sets the name of the configuration file within the indicated configuration directory. If not the default isDEFAULT_CONFIG_FILE
.- Parameters:
fileName
- the name of the journal configuration file- Throws:
ConfigException
- if unable to set the file name
-
getConfigFile
String getConfigFile()Returns the name of the journal configuration file.- Returns:
- the journal configuration file name.
-
setSessionProperties
Sets the session properties that should be logged with journal entries that relate to client sessions.If not set the default is a list with the single entry of "$none", meaning no session properties are logged.
A single entry of "$all" may be specified to log all session properties.
A value of "$user" or "*U" may be used to specify all user session properties.
A value of $fixed" or "*F" may be used to indicates all fixed session properties.
If the first element of the list is "$not" then all session properties except those that follow will be logged.
- Parameters:
sessionProperties
- the list specifying the session properties to be logged- Throws:
ConfigException
- if unable to set the session properties list
-
getSessionProperties
Returns the list specifying the session properties to be logged.- Returns:
- list specifying the session properties to be logged
-