Skip to content

Commit

Permalink
fix: exit directly in debugPrintProcessor when log doesn't have debug…
Browse files Browse the repository at this point in the history
… level enabled (#40081)

(cherry picked from commit 58f4fc8)

# Conflicts:
#	libbeat/publisher/processing/processors.go
  • Loading branch information
pkoutsovasilis authored and mergify[bot] committed Jul 5, 2024
1 parent 81f44d2 commit fc3a2fb
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions libbeat/publisher/processing/processors.go
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,18 @@ func debugPrintProcessor(info beat.Info, log *logp.Logger) *processorFn {
EscapeHTML: false,
})
return newProcessor("debugPrint", func(event *beat.Event) (*beat.Event, error) {
<<<<<<< HEAD

Check failure on line 203 in libbeat/publisher/processing/processors.go

View workflow job for this annotation

GitHub Actions / lint (darwin)

expected statement, found '<<' (typecheck)
if management.TraceLevelEnabled() {
mux.Lock()
defer mux.Unlock()
=======

Check failure on line 207 in libbeat/publisher/processing/processors.go

View workflow job for this annotation

GitHub Actions / lint (darwin)

expected statement, found '==' (typecheck)
if !log.IsDebug() {
return event, nil
}

mux.Lock()
defer mux.Unlock()
>>>>>>> 58f4fc8579 (fix: exit directly in debugPrintProcessor when log doesn't have debug level enabled (#40081))

Check failure on line 214 in libbeat/publisher/processing/processors.go

View workflow job for this annotation

GitHub Actions / lint (darwin)

expected statement, found '>>' (typecheck)

b, err := encoder.Encode(info.Beat, event)
if err != nil {
Expand Down

0 comments on commit fc3a2fb

Please sign in to comment.