Package org.apache.beam.sdk.io.splunk
Class SplunkEvent.Builder
java.lang.Object
org.apache.beam.sdk.io.splunk.SplunkEvent.Builder
- Enclosing class:
SplunkEvent
A builder class for creating a
SplunkEvent
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreate()
Creates aSplunkEvent
object.Assigns the event payload to be sent to the HEC endpoint.withFields
(JsonObject fields) Assigns fields value to the event metadata.Assigns host value to the event metadata.Assigns index value to the event metadata.withSource
(String source) Assigns source value to the event metadata.withSourceType
(String sourceType) Assigns sourceType value to the event metadata.Assigns time value to the event metadata.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
withTime
Assigns time value to the event metadata.- Parameters:
time
- time value to assign
-
withHost
Assigns host value to the event metadata.- Parameters:
host
- host value to assign
-
withSource
Assigns source value to the event metadata.- Parameters:
source
- source value to assign
-
withSourceType
Assigns sourceType value to the event metadata.- Parameters:
sourceType
- sourceType value to assign
-
withIndex
Assigns index value to the event metadata.- Parameters:
index
- index value to assign
-
withFields
Assigns fields value to the event metadata.- Parameters:
fields
- fields value to assign
-
withEvent
Assigns the event payload to be sent to the HEC endpoint.- Parameters:
event
- payload to be sent to HEC
-
create
Creates aSplunkEvent
object.
-