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

Include name of S3 bucket when logging S3 processing error #18679

Merged
merged 1 commit into from
May 28, 2020
Merged

Include name of S3 bucket when logging S3 processing error #18679

merged 1 commit into from
May 28, 2020

Conversation

nhnicwaller
Copy link
Contributor

Enhancement

What does this PR do?

Include name of S3 bucket in error logs when processing fails with s3 input plugin.

Why is it important?

One possible wrapped error says The specified bucket does not exist and this is particularly difficult to troubleshoot when the bucket name is not given. I know that I can get the bucket name by running with logging.level:debug, but that's not helpful when I really need it from the moment of failure. Full error line below:

2020-05-20T21:56:52.119Z	ERROR	[s3]	s3/input.go:386	createEventsFromS3Info failed for AWSLogs/123456789/CloudFront/AB8B8BA8S8D.2020-05-19-22.6400e81a.gz: s3 get object request failed: NoSuchBucket: The specified bucket does not exist

Checklist

  • My code follows the style guidelines of this project
  • [ ] I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation
  • [ ] I have made corresponding change to the default configuration files
  • [ ] I have added tests that prove my fix is effective or that my feature works
  • [ ] I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

@elasticmachine
Copy link
Collaborator

Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually?

1 similar comment
@elasticmachine
Copy link
Collaborator

Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually?

@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label May 20, 2020
@cla-checker-service
Copy link

cla-checker-service bot commented May 20, 2020

💚 CLA has been signed

@elasticmachine
Copy link
Collaborator

❕ Build Aborted

The PR is not allowed to run in the CI yet

Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

Steps errors

Expand to view the steps failures

  • Name: Error signal
    • Description: githubPrCheckApproved: The PR is not allowed to run in the CI yet. (Only users with write permission

    • Result: FAILURE

    • Duration: 0 min 0 sec

    • Start Time: 2020-05-20T22:20:24.444+0000

    • log

Log output

Expand to view the last 100 lines of log output

[2020-05-20T22:20:23.992Z] [WARN] githubApiCall: The REST API call https://api.github.com/repos/elastic/beats/pulls/18679/reviews return 0 elements
[2020-05-20T22:20:24.081Z] [INFO] githubPrCheckApproved: Title: Include name of S3 bucket when logging S3 processing error - User: nhnicwaller - Author Association: FIRST_TIME_CONTRIBUTOR
[2020-05-20T22:20:24.462Z] ERROR: githubPrCheckApproved: The PR is not allowed to run in the CI yet
[2020-05-20T22:20:24.462Z] ERROR: githubPrCheckApproved: The PR is not allowed to run in the CI yet. (Only users with write permissions can do so.)
[2020-05-20T22:20:24.565Z] [INFO] Let's stop build #1. The PR is not allowed to run in the CI yet
[2020-05-20T22:20:24.596Z] Sleeping for 5 sec
[2020-05-20T22:20:25.702Z] Stage "Lint" skipped due to earlier failure(s)
[2020-05-20T22:20:25.816Z] Stage "Build and Test" skipped due to earlier failure(s)
[2020-05-20T22:20:27.007Z] Stage "Elastic Agent x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.019Z] Stage "Elastic Agent x-pack Windows" skipped due to earlier failure(s)
[2020-05-20T22:20:27.029Z] Stage "Elastic Agent Mac OS X" skipped due to earlier failure(s)
[2020-05-20T22:20:27.040Z] Stage "Filebeat oss" skipped due to earlier failure(s)
[2020-05-20T22:20:27.051Z] Stage "Filebeat x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.061Z] Stage "Filebeat Mac OS X" skipped due to earlier failure(s)
[2020-05-20T22:20:27.072Z] Stage "Filebeat x-pack Mac OS X" skipped due to earlier failure(s)
[2020-05-20T22:20:27.083Z] Stage "Filebeat Windows" skipped due to earlier failure(s)
[2020-05-20T22:20:27.094Z] Stage "Filebeat x-pack Windows" skipped due to earlier failure(s)
[2020-05-20T22:20:27.105Z] Stage "Heartbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.110Z] Stage "Auditbeat oss" skipped due to earlier failure(s)
[2020-05-20T22:20:27.116Z] Stage "Auditbeat x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.127Z] Stage "Libbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.132Z] Stage "Libbeat x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.142Z] Stage "Metricbeat OSS Unit tests" skipped due to earlier failure(s)
[2020-05-20T22:20:27.154Z] Stage "Metricbeat OSS Integration tests" skipped due to earlier failure(s)
[2020-05-20T22:20:27.171Z] Stage "Metricbeat Python integration tests" skipped due to earlier failure(s)
[2020-05-20T22:20:27.182Z] Stage "Metricbeat x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.188Z] Stage "Metricbeat crosscompile" skipped due to earlier failure(s)
[2020-05-20T22:20:27.198Z] Stage "Metricbeat Mac OS X" skipped due to earlier failure(s)
[2020-05-20T22:20:27.209Z] Stage "Metricbeat x-pack Mac OS X" skipped due to earlier failure(s)
[2020-05-20T22:20:27.221Z] Stage "Metricbeat Windows" skipped due to earlier failure(s)
[2020-05-20T22:20:27.232Z] Stage "Metricbeat x-pack Windows" skipped due to earlier failure(s)
[2020-05-20T22:20:27.243Z] Stage "Packetbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.249Z] Stage "dockerlogbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.255Z] Stage "Winlogbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.260Z] Stage "Winlogbeat Windows x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.272Z] Stage "Functionbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.277Z] Stage "Journalbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.284Z] Stage "Generators" skipped due to earlier failure(s)
[2020-05-20T22:20:27.289Z] Stage "Kubernetes" skipped due to earlier failure(s)
[2020-05-20T22:20:27.516Z] Stage "Heartbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.526Z] Stage "Auditbeat oss" skipped due to earlier failure(s)
[2020-05-20T22:20:27.534Z] Stage "Libbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.546Z] Stage "Metricbeat x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:27.556Z] Stage "Packetbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.565Z] Stage "dockerlogbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.575Z] Stage "Winlogbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.583Z] Stage "Functionbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.591Z] Stage "Journalbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:27.600Z] Stage "Generators" skipped due to earlier failure(s)
[2020-05-20T22:20:28.385Z] Failed in branch Elastic Agent x-pack
[2020-05-20T22:20:28.393Z] Failed in branch Elastic Agent x-pack Windows
[2020-05-20T22:20:28.402Z] Failed in branch Elastic Agent Mac OS X
[2020-05-20T22:20:28.410Z] Failed in branch Filebeat oss
[2020-05-20T22:20:28.418Z] Failed in branch Filebeat x-pack
[2020-05-20T22:20:28.426Z] Failed in branch Filebeat Mac OS X
[2020-05-20T22:20:28.434Z] Failed in branch Filebeat x-pack Mac OS X
[2020-05-20T22:20:28.442Z] Failed in branch Filebeat Windows
[2020-05-20T22:20:28.450Z] Failed in branch Filebeat x-pack Windows
[2020-05-20T22:20:28.458Z] Failed in branch Auditbeat x-pack
[2020-05-20T22:20:28.467Z] Failed in branch Libbeat x-pack
[2020-05-20T22:20:28.475Z] Failed in branch Metricbeat OSS Unit tests
[2020-05-20T22:20:28.483Z] Failed in branch Metricbeat OSS Integration tests
[2020-05-20T22:20:28.491Z] Failed in branch Metricbeat Python integration tests
[2020-05-20T22:20:28.500Z] Failed in branch Metricbeat crosscompile
[2020-05-20T22:20:28.508Z] Failed in branch Metricbeat Mac OS X
[2020-05-20T22:20:28.515Z] Failed in branch Metricbeat x-pack Mac OS X
[2020-05-20T22:20:28.524Z] Failed in branch Metricbeat Windows
[2020-05-20T22:20:28.531Z] Failed in branch Metricbeat x-pack Windows
[2020-05-20T22:20:28.539Z] Failed in branch Winlogbeat Windows x-pack
[2020-05-20T22:20:28.547Z] Failed in branch Kubernetes
[2020-05-20T22:20:29.135Z] Stage "Heartbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:29.145Z] Stage "Auditbeat oss" skipped due to earlier failure(s)
[2020-05-20T22:20:29.155Z] Stage "Libbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:29.164Z] Stage "Metricbeat x-pack" skipped due to earlier failure(s)
[2020-05-20T22:20:29.173Z] Stage "Winlogbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:29.181Z] Stage "Functionbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:29.190Z] Stage "Generators" skipped due to earlier failure(s)
[2020-05-20T22:20:29.565Z] Failed in branch Packetbeat
[2020-05-20T22:20:29.574Z] Failed in branch dockerlogbeat
[2020-05-20T22:20:29.582Z] Failed in branch Journalbeat
[2020-05-20T22:20:30.044Z] Stage "Heartbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:30.054Z] Stage "Auditbeat oss" skipped due to earlier failure(s)
[2020-05-20T22:20:30.063Z] Stage "Libbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:30.072Z] Stage "Functionbeat" skipped due to earlier failure(s)
[2020-05-20T22:20:30.081Z] Stage "Generators" skipped due to earlier failure(s)
[2020-05-20T22:20:30.179Z] Failed in branch Metricbeat x-pack
[2020-05-20T22:20:30.187Z] Failed in branch Winlogbeat
[2020-05-20T22:20:30.626Z] Failed in branch Heartbeat
[2020-05-20T22:20:30.634Z] Failed in branch Libbeat
[2020-05-20T22:20:30.642Z] Failed in branch Functionbeat
[2020-05-20T22:20:30.643Z] Stage "Auditbeat oss" skipped due to earlier failure(s)
[2020-05-20T22:20:30.652Z] Stage "Generators" skipped due to earlier failure(s)
[2020-05-20T22:20:30.912Z] Failed in branch Auditbeat oss
[2020-05-20T22:20:30.921Z] Failed in branch Generators
[2020-05-20T22:20:32.431Z] Running on Jenkins in /var/lib/jenkins/workspace/Beats_beats-beats-mbp_PR-18679
[2020-05-20T22:20:32.600Z] [INFO] getVaultSecret: Getting secrets
[2020-05-20T22:20:32.679Z] Masking supported pattern matches of $VAULT_ADDR or $VAULT_ROLE_ID or $VAULT_SECRET_ID
[2020-05-20T22:20:33.662Z] + chmod 755 generate-build-data.sh
[2020-05-20T22:20:33.662Z] + ./generate-build-data.sh https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats-beats-mbp/PR-18679/ https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats-beats-mbp/PR-18679/runs/1 ABORTED 127307
[2020-05-20T22:20:33.917Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats-beats-mbp/PR-18679/runs/1/steps/?limit=10000 -o steps-info.json

@ChrsMark ChrsMark added the Team:Platforms Label for the Integrations - Platforms team label May 21, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations-platforms (Team:Platforms)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label May 21, 2020
@ChrsMark
Copy link
Member

@nhnicwaller could you please sign the CLA?

@nhnicwaller
Copy link
Contributor Author

nhnicwaller commented May 21, 2020

@ChrsMark After making this pull request I did sign the CLA and associated it with the username of this account on GitHub. But it didn't seem to update the status of the check on this PR? Is there something additional I need to do?

@kaiyan-sheng
Copy link
Contributor

jenkins, test this please

Copy link
Contributor

@kaiyan-sheng kaiyan-sheng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for making the change, this will be definitely helpful!

@kaiyan-sheng kaiyan-sheng added the needs_backport PR is waiting to be backported to other branches. label May 21, 2020
@kaiyan-sheng kaiyan-sheng self-assigned this May 21, 2020
@kaiyan-sheng kaiyan-sheng merged commit df6f216 into elastic:master May 28, 2020
@kaiyan-sheng kaiyan-sheng added v7.9.0 and removed needs_backport PR is waiting to be backported to other branches. labels May 28, 2020
kaiyan-sheng added a commit that referenced this pull request May 29, 2020
(cherry picked from commit df6f216)

Co-authored-by: Nic Waller <42976427+nhnicwaller@users.noreply.github.com>
kaiyan-sheng added a commit that referenced this pull request May 29, 2020
(cherry picked from commit df6f216)

Co-authored-by: Nic Waller <42976427+nhnicwaller@users.noreply.github.com>
kaiyan-sheng added a commit that referenced this pull request May 29, 2020
(cherry picked from commit df6f216)

Co-authored-by: Nic Waller <42976427+nhnicwaller@users.noreply.github.com>
v1v added a commit to v1v/beats that referenced this pull request Jun 2, 2020
…-stage-level

* upstream/master: (30 commits)
  Add a GRPC listener service for Agent (elastic#18827)
  Disable host.* fields by default for iptables module (elastic#18756)
  [WIP] Clarify capabilities of the Filebeat auditd module (elastic#17068)
  fix: rename file and remove extra separator (elastic#18881)
  ci: enable JJBB (elastic#18812)
  Disable host.* fields by default for Checkpoint module (elastic#18754)
  Disable host.* fields by default for Cisco module (elastic#18753)
  Update latest.yml testing env to 7.7.0 (elastic#18535)
  Upgrade k8s.io/client-go and k8s keystore tests (elastic#18817)
  Add missing Jenkins stages for Auditbeat (elastic#18835)
  [Elastic Log Driver] Create a config shim between libbeat and the user (elastic#18605)
  Use indexers and matchers in config when defaults are enabled (elastic#18818)
  Fix panic on `metricbeat test modules` (elastic#18797)
  [CI] Fix permissions in MacOSX agents (elastic#18847)
  [Ingest Manager] When not port are specified and the https is used fallback to 443 (elastic#18844)
  [Ingest Manager] Fix install service script for windows (elastic#18814)
  [Metricbeat] Fix getting compute instance metadata with partial zone/region config (elastic#18757)
  Improve error messages in s3 input (elastic#18824)
  Add memory metrics into compute googlecloud (elastic#18802)
  include bucket name when logging error (elastic#18679)
  ...
leweafan pushed a commit to leweafan/beats that referenced this pull request Apr 28, 2023
(cherry picked from commit b7a76f3)

Co-authored-by: Nic Waller <42976427+nhnicwaller@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:Platforms Label for the Integrations - Platforms team v7.7.1 v7.8.0 v7.9.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants