diff --git a/pkg/exporter/sumologicexporter/config.go b/pkg/exporter/sumologicexporter/config.go index b11b5ce9b8..eb8f958046 100644 --- a/pkg/exporter/sumologicexporter/config.go +++ b/pkg/exporter/sumologicexporter/config.go @@ -208,12 +208,6 @@ const ( DefaultClearLogsTimestamp bool = true // DefaultLogKey defines default LogKey value DefaultLogKey string = "log" - // DefaultAddTimestamp defines default AddTimestamp value - DefaultAddTimestamp bool = true - // DefaultTimestampKey defines default TimestampKey value - DefaultTimestampKey string = "timestamp" - // DefaultFlattenBody defines default FlattenBody value - DefaultFlattenBody bool = false // DefaultDropRoutingAttribute defines default DropRoutingAttribute DefaultDropRoutingAttribute string = "" // DefaultStickySessionEnabled defines default StickySessionEnabled value diff --git a/pkg/exporter/sumologicexporter/sender.go b/pkg/exporter/sumologicexporter/sender.go index 66f7a1c7a1..31976ae106 100644 --- a/pkg/exporter/sumologicexporter/sender.go +++ b/pkg/exporter/sumologicexporter/sender.go @@ -359,7 +359,7 @@ func (s *sender) logToJSON(record plog.LogRecord) (string, error) { // Only append the body when it's not empty to prevent sending 'null' log. if body := recordCopy.Body(); !isEmptyAttributeValue(body) { - body.CopyTo(recordCopy.Attributes().PutEmpty("log")) + body.CopyTo(recordCopy.Attributes().PutEmpty(DefaultLogKey)) } nextLine := new(bytes.Buffer)