Class LogInput
java.lang.Object
codes.grow.packages.graylog.logging.LogInput
- All Implemented Interfaces:
LogEntry
Short form of a log record: a message plus optional severity, attributes, timestamp and trace
ids. The
LogClient fills in the timestamp, the resource and (when a span is active) the
trace correlation.-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionAttributes.static LogInput.BuilderReturns a builder formessage.message()Message.static LogInputCreates an input with a severity and attributes.static LogInputCreates an INFO input with no attributes.severity()Severity (default INFO).spanId()Span id.Event time.toString()traceId()Trace id.
-
Method Details
-
of
Creates an INFO input with no attributes.- Parameters:
message- the message- Returns:
- the input
-
of
Creates an input with a severity and attributes.- Parameters:
severity- severitymessage- the messageattributes- attributes (may benull)- Returns:
- the input
-
builder
Returns a builder formessage.- Parameters:
message- the message- Returns:
- builder
-
message
Message.- Returns:
- message
-
severity
Severity (default INFO).- Returns:
- severity
-
attributes
Attributes.- Returns:
- immutable attributes
-
timestamp
Event time.- Returns:
- timestamp, if set
-
traceId
Trace id.- Returns:
- trace id, if set
-
spanId
Span id.- Returns:
- span id, if set
-
toString
-