Class SyslogAuditEventHandlerConfiguration
java.lang.Object
org.forgerock.audit.events.handlers.EventHandlerConfiguration
org.forgerock.audit.handlers.syslog.SyslogAuditEventHandlerConfiguration
Configuration object for the
SyslogAuditEventHandler.
This configuration object can be created from JSON. Example of valid JSON configuration:
{
"protocol" : "TCP",
"host" : "https://forgerock.example.com",
"port" : 6514,
"connectTimeout" : 30000,
"facility" : "local0",
"severityFieldMappings": [{
"topic" : "system-status",
"field" : "level",
"valueMappings" : {
"SEVERE" : "EMERGENCY",
"WARNING" : "WARNING",
"INFO" : "INFORMATIONAL"
},
"buffering" : {
"enabled" : "true"
}
}]
}
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classConfiguration of event buffering.static final classEncapsulates configuration for mapping audit event field values to Syslog severity values. -
Field Summary
FieldsModifier and TypeFieldDescriptionEvent buffering is disabled by default. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the configuration for events buffering.intReturns the timeout after which attempts to connect to the Syslog daemon will be abandoned.Returns the facility constant that should be applied to all Syslog messages.getHost()Returns the hostname of the Syslog daemon to which messages should be published.intgetPort()Returns the port of the Syslog daemon to which messages should be published.Returns the protocol over which messages transmitted to the Syslog daemon.Returns the configurations for mapping audit event field values to Syslog severity values.booleanStates if anAuditEventHandlercan be used for queries.voidsetBufferingConfiguration(SyslogAuditEventHandlerConfiguration.EventBufferingConfiguration bufferingConfiguration) Sets the configuration for events buffering.voidsetConnectTimeout(int connectTimeout) Sets the timeout after which attempts to connect to the Syslog daemon will be abandoned.voidsetFacility(Facility facility) Sets the facility constant that should be applied to all Syslog messages.voidSets the hostname of the Syslog daemon to which messages should be published.voidsetPort(int port) Sets the port of the Syslog daemon to which messages should be published.voidsetProtocol(TransportProtocol protocol) Sets the protocol over which messages transmitted to the Syslog daemon.voidsetSeverityFieldMappings(List<SyslogAuditEventHandlerConfiguration.SeverityFieldMapping> severityFieldMappings) Sets the configurations for mapping audit event field values to Syslog severity values.Methods inherited from class org.forgerock.audit.events.handlers.EventHandlerConfiguration
getName, getTopics, isEnabled, setEnabled, setName, setTopics
-
Field Details
-
buffering
@JsonPropertyDescription("audit.handlers.syslog.buffering") protected SyslogAuditEventHandlerConfiguration.EventBufferingConfiguration bufferingEvent buffering is disabled by default.
-
-
Constructor Details
-
SyslogAuditEventHandlerConfiguration
public SyslogAuditEventHandlerConfiguration()
-
-
Method Details
-
getProtocol
Returns the protocol over which messages transmitted to the Syslog daemon.- Returns:
- the transport protocol.
-
setProtocol
Sets the protocol over which messages transmitted to the Syslog daemon.- Parameters:
protocol- the transport protocol.
-
getHost
Returns the hostname of the Syslog daemon to which messages should be published.- Returns:
- the hostname.
-
setHost
Sets the hostname of the Syslog daemon to which messages should be published.- Parameters:
host- the hostname.
-
getPort
public int getPort()Returns the port of the Syslog daemon to which messages should be published.- Returns:
- the port.
-
setPort
public void setPort(int port) Sets the port of the Syslog daemon to which messages should be published.- Parameters:
port- the port.
-
getConnectTimeout
public int getConnectTimeout()Returns the timeout after which attempts to connect to the Syslog daemon will be abandoned.Only applies when
TransportProtocol.TCPis active.- Returns:
- the connect timeout.
-
setConnectTimeout
public void setConnectTimeout(int connectTimeout) Sets the timeout after which attempts to connect to the Syslog daemon will be abandoned.Only applies when
TransportProtocol.TCPis active.- Parameters:
connectTimeout- the connect timeout.
-
getFacility
Returns the facility constant that should be applied to all Syslog messages.- Returns:
- the facility.
- See Also:
-
setFacility
Sets the facility constant that should be applied to all Syslog messages.- Parameters:
facility- the facility.- See Also:
-
getSeverityFieldMappings
Returns the configurations for mapping audit event field values to Syslog severity values.- Returns:
- the severity field mappings.
-
setSeverityFieldMappings
public void setSeverityFieldMappings(List<SyslogAuditEventHandlerConfiguration.SeverityFieldMapping> severityFieldMappings) Sets the configurations for mapping audit event field values to Syslog severity values.- Parameters:
severityFieldMappings- the severity field mappings.
-
getBuffering
Returns the configuration for events buffering.- Returns:
- the configuration
-
setBufferingConfiguration
public void setBufferingConfiguration(SyslogAuditEventHandlerConfiguration.EventBufferingConfiguration bufferingConfiguration) Sets the configuration for events buffering.- Parameters:
bufferingConfiguration- The configuration
-
isUsableForQueries
public boolean isUsableForQueries()Description copied from class:EventHandlerConfigurationStates if anAuditEventHandlercan be used for queries.- Specified by:
isUsableForQueriesin classEventHandlerConfiguration- Returns:
- True - If the
AuditEventHandlercan be used for queries. False - If theAuditEventHandlercan not be used for queries.
-