Package org.wso2.carbon.logging.service
Interface RemoteLoggingConfigService
-
- All Known Implementing Classes:
RemoteLoggingConfig
public interface RemoteLoggingConfigServiceThis is the interface used for configuring the remote server logging configurations.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidaddRemoteServerConfig(RemoteServerLoggerData data)This method is used to add a remote server configuration.voidaddRemoteServerConfig(RemoteServerLoggerData data, boolean isPeriodicalSyncRequest)This method is used to add a remote server configuration.RemoteServerLoggerDatagetRemoteServerConfig(String logType)This method is used to get the remote server configuration for a given log type.default RemoteServerLoggerDatagetRemoteServerConfig(String logType, boolean includeSecrets)This method is used to get the remote server configuration for a given log type.List<RemoteServerLoggerData>getRemoteServerConfigs()This method is used to get the remote server configurations.default List<RemoteServerLoggerData>getRemoteServerConfigs(boolean includeSecrets)This method is used to get the remote server configurations.voidresetRemoteServerConfig(RemoteServerLoggerData data)This method is used to reset the remote server configurations to the defaults.voidresetRemoteServerConfig(RemoteServerLoggerData data, boolean isPeriodicalSyncRequest)This method is used to reset the remote server configurations to the defaults.voidsyncRemoteServerConfigs()This method is used to sync the remote server configurations with the remote server.
-
-
-
Method Detail
-
addRemoteServerConfig
void addRemoteServerConfig(RemoteServerLoggerData data) throws IOException, org.apache.commons.configuration2.ex.ConfigurationException
This method is used to add a remote server configuration.- Parameters:
data- RemoteServerLoggerData object that contains the remote server configuration.- Throws:
IOException- If an error occurs while writing to the log4j2.properties file.org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
addRemoteServerConfig
void addRemoteServerConfig(RemoteServerLoggerData data, boolean isPeriodicalSyncRequest) throws IOException, org.apache.commons.configuration2.ex.ConfigurationException
This method is used to add a remote server configuration.- Parameters:
data- RemoteServerLoggerData object that contains the remote server configuration.isPeriodicalSyncRequest- Boolean value to indicate whether the request is a periodical sync request or not.- Throws:
IOException- If an error occurs while writing to the log4j2.properties file.org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
resetRemoteServerConfig
void resetRemoteServerConfig(RemoteServerLoggerData data) throws IOException, org.apache.commons.configuration2.ex.ConfigurationException
This method is used to reset the remote server configurations to the defaults.- Parameters:
data- RemoteServerLoggerData object that contains the remote server configuration.- Throws:
IOException- If an error occurs while writing to the log4j2.properties file.org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
resetRemoteServerConfig
void resetRemoteServerConfig(RemoteServerLoggerData data, boolean isPeriodicalSyncRequest) throws IOException, org.apache.commons.configuration2.ex.ConfigurationException
This method is used to reset the remote server configurations to the defaults.- Parameters:
data- RemoteServerLoggerData object that contains the remote server configuration.isPeriodicalSyncRequest- Boolean value to indicate whether the request is a periodical sync request or not.- Throws:
IOException- If an error occurs while writing to the log4j2.properties file.org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
getRemoteServerConfigs
List<RemoteServerLoggerData> getRemoteServerConfigs() throws org.apache.commons.configuration2.ex.ConfigurationException
This method is used to get the remote server configurations.- Returns:
- List of RemoteServerLoggerData objects that contains the remote server configurations.
- Throws:
org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
getRemoteServerConfigs
default List<RemoteServerLoggerData> getRemoteServerConfigs(boolean includeSecrets) throws org.apache.commons.configuration2.ex.ConfigurationException
This method is used to get the remote server configurations.- Parameters:
includeSecrets- Boolean value to indicate whether to include secrets in the response or not.- Returns:
- List of RemoteServerLoggerData objects that contains the remote server configurations.
- Throws:
org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
getRemoteServerConfig
RemoteServerLoggerData getRemoteServerConfig(String logType) throws org.apache.commons.configuration2.ex.ConfigurationException
This method is used to get the remote server configuration for a given log type.- Parameters:
logType- The log type of the remote server configuration.- Returns:
- RemoteServerLoggerData object that contains the remote server configuration.
- Throws:
org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
getRemoteServerConfig
default RemoteServerLoggerData getRemoteServerConfig(String logType, boolean includeSecrets) throws org.apache.commons.configuration2.ex.ConfigurationException
This method is used to get the remote server configuration for a given log type.- Parameters:
logType- The log type of the remote server configuration.includeSecrets- Boolean value to indicate whether to include secrets in the response or not.- Returns:
- RemoteServerLoggerData object that contains the remote server configuration.
- Throws:
org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the log4j2.properties file.
-
syncRemoteServerConfigs
void syncRemoteServerConfigs() throws org.apache.commons.configuration2.ex.ConfigurationException, IOExceptionThis method is used to sync the remote server configurations with the remote server.- Throws:
org.apache.commons.configuration2.ex.ConfigurationException- If an error occurs while loading the configurations from database.IOException
-
-