Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue 11543 when key 'log' does not exist #11549

Merged
merged 4 commits into from
Mar 30, 2019
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.next.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ https://github.com/elastic/beats/compare/v7.0.0-alpha2...master[Check the HEAD d
- Add fix to parse syslog message with priority value 0. {issue}11010[11010]
- Don't apply multiline rules in Logstash json logs. {pull}11346[11346]
- Fix coredns image in docs.asciidoc for docs build. {pull}11460[11460] {pull}11461[11461]
- Fix issue 11543 when key `log` does not exist. {pull}11549[11549]
alakahakai marked this conversation as resolved.
Show resolved Hide resolved

*Heartbeat*

Expand Down
3 changes: 2 additions & 1 deletion filebeat/processor/add_kubernetes_metadata/matchers.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ const containerIdLen = 64
const podUIDPos = 5

func (f *LogPathMatcher) MetadataIndex(event common.MapStr) string {
if value, ok := event["log"].(common.MapStr)["file"].(common.MapStr)["path"]; ok {
value, err := event.GetValue("log.file.path")
if err == nil {
alakahakai marked this conversation as resolved.
Show resolved Hide resolved
source := value.(string)
logp.Debug("kubernetes", "Incoming log.file.path value: %s", source)

Expand Down