Class JsonPathInput
java.lang.Object
org.graylog2.plugin.inputs.MessageInput
org.graylog2.inputs.misc.jsonpath.JsonPathInput
- All Implemented Interfaces:
Stoppable
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static interface
-
Field Summary
Fields inherited from class org.graylog2.plugin.inputs.MessageInput
configuration, contentPack, createdAt, creatorUserId, desiredState, FIELD_ATTRIBUTES, FIELD_CONFIGURATION, FIELD_CONTENT_PACK, FIELD_CREATED_AT, FIELD_CREATOR_USER_ID, FIELD_DESIRED_STATE, FIELD_GLOBAL, FIELD_ID, FIELD_NAME, FIELD_NODE_ID, FIELD_STARTED_AT, FIELD_STATIC_FIELDS, FIELD_TITLE, FIELD_TYPE, global, inputBuffer, persistId, title
-
Constructor Summary
ConstructorDescriptionJsonPathInput
(Configuration configuration, HttpPollTransport.Factory transport, JsonPathCodec.Factory codec, com.codahale.metrics.MetricRegistry metricRegistry, LocalMetricRegistry localRegistry, JsonPathInput.Config config, JsonPathInput.Descriptor descriptor, ServerStatus serverStatus) -
Method Summary
Modifier and TypeMethodDescriptionboolean
Determines if Graylog should only launch a single instance of this input at a time in the cluster.Methods inherited from class org.graylog2.plugin.inputs.MessageInput
addStaticField, addStaticFields, asMap, asMapMasked, checkConfiguration, equals, getAttributesWithMaskedPasswords, getCodec, getConfiguration, getContentPack, getCreatedAt, getCreatorUserId, getDefaultRecvBufferSize, getDescriptor, getDesiredState, getId, getName, getNodeId, getPersistId, getRequestedConfiguration, getStaticFields, getTitle, getType, getUniqueReadableId, hashCode, initialize, isCloudCompatible, isExclusive, isForwarderCompatible, isGlobal, launch, launch, processRawMessage, setContentPack, setCreatedAt, setCreatorUserId, setDefaultRecvBufferSize, setDesiredState, setGlobal, setNodeId, setPersistId, setTitle, stop, terminate, toIdentifier, toString
-
Constructor Details
-
JsonPathInput
public JsonPathInput(Configuration configuration, HttpPollTransport.Factory transport, JsonPathCodec.Factory codec, com.codahale.metrics.MetricRegistry metricRegistry, LocalMetricRegistry localRegistry, JsonPathInput.Config config, JsonPathInput.Descriptor descriptor, ServerStatus serverStatus)
-
-
Method Details
-
onlyOnePerCluster
public boolean onlyOnePerCluster()Description copied from class:MessageInput
Determines if Graylog should only launch a single instance of this input at a time in the cluster.This might be useful for an input which polls data from an external source and maintains local state, i.e. a cursor, to determine records have been fetched already. In that case, running a second instance of the input at the same time on a different node in the cluster might then lead to the same data fetched again, which would produce duplicate log messages in Graylog.
Returning
true
from this method will only really make sense if the input alsoisGlobal
.- Overrides:
onlyOnePerCluster
in classMessageInput
- Returns:
true
if only a single instance of the input should be launched in the cluster. It will be launched on the leader node.false
otherwise
-