Class ElasticsearchAuditEventHandlerConfiguration
java.lang.Object
org.forgerock.audit.events.handlers.EventHandlerConfiguration
org.forgerock.audit.handlers.elasticsearch.ElasticsearchAuditEventHandlerConfiguration
A configuration for Elasticsearch audit event handler.
This configuration object can be created from JSON. Example of valid JSON configuration:
{ "name" : "elasticsearch", "topics": [ "access", "activity", "config", "authentication" ], "connection" : { "useSSL" : true, "host" : "localhost", "port" : 9200, "username" : "myUsername", "password" : "myPassword" }, "indexMapping" : { "indexName" : "audit" }, "buffering" : { "enabled" : true, "maxSize" : 10000, "writeInterval" : "250 millis", "maxBatchedEvents" : 500 } }
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Configuration of connection to Elasticsearch.static class
Configuration of event buffering.static class
Configuration of index mapping. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGets configuration of event buffering.Gets configuration of connection to Elasticsearch.Sets configuration of index mapping.boolean
States if anAuditEventHandler
can be used for queries.void
Sets configuration of event buffering.void
Sets configuration of connection to Elasticsearch.void
Gets configuration of index mapping.Methods inherited from class org.forgerock.audit.events.handlers.EventHandlerConfiguration
getName, getTopics, isEnabled, setEnabled, setName, setTopics
-
Constructor Details
-
ElasticsearchAuditEventHandlerConfiguration
public ElasticsearchAuditEventHandlerConfiguration()
-
-
Method Details
-
getConnection
Gets configuration of connection to Elasticsearch.- Returns:
- configuration of connection to Elasticsearch
-
setConnection
public void setConnection(ElasticsearchAuditEventHandlerConfiguration.ConnectionConfiguration connection) Sets configuration of connection to Elasticsearch.- Parameters:
connection
- configuration of connection to Elasticsearch
-
getIndexMapping
Sets configuration of index mapping.- Returns:
- configuration of index mapping
-
setIndexMapping
public void setIndexMapping(ElasticsearchAuditEventHandlerConfiguration.IndexMappingConfiguration indexMapping) Gets configuration of index mapping.- Parameters:
indexMapping
- configuration of index mapping
-
getBuffering
Gets configuration of event buffering.- Returns:
- configuration of event buffering
-
setBuffering
public void setBuffering(ElasticsearchAuditEventHandlerConfiguration.EventBufferingConfiguration buffering) Sets configuration of event buffering.- Parameters:
buffering
- configuration of event buffering
-
isUsableForQueries
public boolean isUsableForQueries()Description copied from class:EventHandlerConfiguration
States if anAuditEventHandler
can be used for queries.- Specified by:
isUsableForQueries
in classEventHandlerConfiguration
- Returns:
- True - If the
AuditEventHandler
can be used for queries. False - If theAuditEventHandler
can not be used for queries.
-