-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
[libbeat] Don't swallow Kibana index pattern errors #20121
[libbeat] Don't swallow Kibana index pattern errors #20121
Conversation
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways.
62d5efc
to
b765766
Compare
Pinging @elastic/integrations-services (Team:Services) |
On a related note |
Looks like the index pattern issue was reported in #19965. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we have linter rules to look for unchecked errors? I'm assuming not because they're generally noisy and not always useful, but wondering if we should in the long-run b/c that for sure would have caught this.
None at this time. We've had a few in the past and they weren't removed for any good reason AFAIK. I think it was just that nobody was maintaining them. Previously we used Hound CI to comment, but it wasn't very configurable IIRC. And before that we had reviewdog running. I use golangci-lint locally when I'm making changes. I'd be interested in trying out their Github action on PRs. https://github.com/marketplace/actions/run-golangci-lint |
that would be nice, I just ran it over the whole codebase, there are a good number of ineffectual assignments/lack off error checks it found: https://gist.github.com/andrewstucki/5cfc32b8024ac23bd4ae1edb2bbb4565 |
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways. (cherry picked from commit 7a7279f)
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways. (cherry picked from commit 7a7279f)
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways. (cherry picked from commit 7a7279f)
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways. (cherry picked from commit 7a7279f)
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways.
) While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored. This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways. (cherry picked from commit 543349c)
What does this PR do?
While running 'beat setup --dashboads' any errors that occur while importing the generated Kibana index pattern or silently ignored.
This changes that by causing the dashboard setup to stop and return the error. Dashboards won't work without the index pattern anyways.
Why is it important?
Errors with the Kibana index pattern were undetected. The only hint of an error is that the index pattern doesn't exist in Kibana after setup.
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Logs
2020-07-21T18:26:27.006-0400 ERROR instance/beat.go:935 Exiting: 1 error: error loading index pattern: returned 413 to import file: <nil>. Response: {"statusCode":413,"error":"Request Entity Too Large","message":"Payload content length greater than maximum allowed: 1048576"}