public class EventToIndex extends Object implements AutoCloseable
Modifier and Type | Class and Description |
---|---|
static class |
EventToIndex.Indices |
Constructor and Description |
---|
EventToIndex() |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
forwardEvents(List<Event> events) |
boolean |
getArchiveAlarmChangeEvents() |
boolean |
getArchiveAlarms() |
boolean |
getArchiveNewAlarmValues() |
boolean |
getArchiveOldAlarmValues() |
boolean |
getArchiveRawEvents() |
IndexNameFunction |
getIndexNameFunction() |
NodeCache |
getNodeCache() |
RestClientFactory |
getRestClientFactory() |
int |
getThreads() |
boolean |
isLogAllEvents() |
boolean |
isLogEventDescription() |
io.searchbox.core.Update |
populateAlarmIndexBodyFromAlarmChangeEvent(Event event,
String rootIndexName,
String indexType)
An alarm change event will have a payload corresponding to the json representation of the
Alarms table row for this alarm id.
|
io.searchbox.core.Index |
populateEventIndexBodyFromEvent(Event event,
String rootIndexName,
String indexType)
utility method to populate a Map with the most import event attributes
|
void |
setArchiveAlarmChangeEvents(boolean archiveAlarmChangeEvents) |
void |
setArchiveAlarms(boolean archiveAlarms) |
void |
setArchiveNewAlarmValues(boolean archiveNewAlarmValues) |
void |
setArchiveOldAlarmValues(boolean archiveOldAlarmValues) |
void |
setArchiveRawEvents(boolean archiveRawEvents) |
void |
setIndexNameFunction(IndexNameFunction indexNameFunction) |
void |
setLogAllEvents(boolean logAllEvents) |
void |
setLogEventDescription(boolean logEventDescription) |
void |
setNodeCache(NodeCache cache) |
void |
setRestClientFactory(RestClientFactory restClientFactory) |
void |
setThreads(int threads) |
public static final EnumMap<EventToIndex.Indices,String> INDEX_NAMES
public static final EnumMap<EventToIndex.Indices,String> INDEX_TYPES
public static final String ALARM_NOTIFICATION_UEI_STEM
public static final String ALARM_DELETED_EVENT
public static final String ALARM_CREATED_EVENT
public static final String ALARM_SEVERITY_CHANGED_EVENT
public static final String ALARM_CLEARED_EVENT
public static final String ALARM_ACKNOWLEDGED_EVENT
public static final String ALARM_UNACKNOWLEDGED_EVENT
public static final String ALARM_SUPPRESSED_EVENT
public static final String ALARM_UNSUPPRESSED_EVENT
public static final String ALARM_TROUBLETICKET_STATE_CHANGE_EVENT
public static final String ALARM_CHANGED_EVENT
public static final String STICKY_MEMO_EVENT
public static final String JOURNAL_MEMO_EVENT
public static final String MEMO_VALUES_PARAM
public static final String MEMO_ALARMID_PARAM
public static final String MEMO_BODY_PARAM
public static final String MEMO_AUTHOR_PARAM
public static final String MEMO_REDUCTIONKEY_PARAM
public static final String OLD_ALARM_VALUES_PARAM
public static final String NEW_ALARM_VALUES_PARAM
public static final String NODE_LABEL_PARAM
public static final String INITIAL_SEVERITY_PARAM
public static final String INITIAL_SEVERITY_PARAM_TEXT
public static final String SEVERITY_TEXT
public static final String SEVERITY
public static final String ALARM_SEVERITY_PARAM
public static final String FIRST_EVENT_TIME
public static final String EVENT_PARAMS
public static final String ALARM_ACK_TIME_PARAM
public static final String ALARM_ACK_USER_PARAM
public static final String ALARM_ACK_DURATION
public static final String ALARM_CLEAR_TIME
public static final String ALARM_CLEAR_DURATION
public static final String ALARM_DELETED_TIME
public static final int DEFAULT_NUMBER_OF_THREADS
public IndexNameFunction getIndexNameFunction()
public void setIndexNameFunction(IndexNameFunction indexNameFunction)
public boolean isLogEventDescription()
public void setLogEventDescription(boolean logEventDescription)
public boolean isLogAllEvents()
public void setLogAllEvents(boolean logAllEvents)
public int getThreads()
public void setThreads(int threads)
public NodeCache getNodeCache()
public void setNodeCache(NodeCache cache)
public RestClientFactory getRestClientFactory()
public void setRestClientFactory(RestClientFactory restClientFactory)
public boolean getArchiveAlarms()
public void setArchiveAlarms(boolean archiveAlarms)
public boolean getArchiveAlarmChangeEvents()
public void setArchiveAlarmChangeEvents(boolean archiveAlarmChangeEvents)
public boolean getArchiveRawEvents()
public void setArchiveRawEvents(boolean archiveRawEvents)
public boolean getArchiveOldAlarmValues()
public void setArchiveOldAlarmValues(boolean archiveOldAlarmValues)
public boolean getArchiveNewAlarmValues()
public void setArchiveNewAlarmValues(boolean archiveNewAlarmValues)
public void close()
close
in interface AutoCloseable
public io.searchbox.core.Index populateEventIndexBodyFromEvent(Event event, String rootIndexName, String indexType)
body
- the mapevent
- the event objectpublic io.searchbox.core.Update populateAlarmIndexBodyFromAlarmChangeEvent(Event event, String rootIndexName, String indexType)
body
- event
- Copyright © 2020. All rights reserved.