Skip to content

Commit

Permalink
Merge pull request containers#3812 from baude/perffix1
Browse files Browse the repository at this point in the history
performance fix for podman events with large journalds
  • Loading branch information
openshift-merge-robot committed Aug 15, 2019
2 parents f9ddf91 + bbfc80c commit 3f1657d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions libpod/events/journal_linux.go
Expand Up @@ -73,6 +73,11 @@ func (e EventJournalD) Read(options ReadOptions) error {
if err := j.SeekTail(); err != nil {
return errors.Wrap(err, "failed to seek end of journal")
}
} else {
podmanJournal := sdjournal.Match{Field: "SYSLOG_IDENTIFIER", Value: "podman"} //nolint
if err := j.AddMatch(podmanJournal.String()); err != nil {
return errors.Wrap(err, "failed to add filter for event log")
}
}
// the api requires a next|prev before getting a cursor
if _, err := j.Next(); err != nil {
Expand Down

0 comments on commit 3f1657d

Please sign in to comment.