Skip to content

Commit

Permalink
parse: auto-guess Pachyderm worker log schema
Browse files Browse the repository at this point in the history
  • Loading branch information
jrockway committed Jun 18, 2022
1 parent a2d977b commit 18d824a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pkg/parse/parse.go
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,14 @@ func (s *InputSchema) guessSchema(l *line) {
s.UpgradeKeys = append(s.UpgradeKeys, "data")
return
}
if has("ts") && has("message") && has("workerId") && has("pipelineName") {
// Pachyderm worker logs.
s.TimeKey = "ts"
s.TimeFormat = DefaultTimeParser // RFC3339Nano
s.NoLevelKey = true
s.MessageKey = "message"
return
}
}

// ReadLine parses a log line into the provided line object.
Expand Down

0 comments on commit 18d824a

Please sign in to comment.