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

not setting queue_url bucket_arn or non_aws_bucket_name returns error #28666

Merged
merged 5 commits into from
Oct 28, 2021
Merged

not setting queue_url bucket_arn or non_aws_bucket_name returns error #28666

merged 5 commits into from
Oct 28, 2021

Conversation

aspacca
Copy link

@aspacca aspacca commented Oct 27, 2021

Breaking Change

What does this PR do?

In case an aws-s3 input has no source param defined in the config (either queue_url, bucket_arn or non_aws_bucket_name) loading the input will return an error on config validation and stop Filebeat

Why is it important?

Giving a proper blocking failure error message instead of silently fail loading the input will improve troubleshooting issue in the aws s3 input.
The same solution was not possible in 7.x due to loading and validating every filesets existing for a module regardless they were configured or not

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.

Author's Checklist

  • [ ]

How to test this PR locally

Related issues

Relates #13911
Requires #27526

Use cases

Screenshots

Logs

2021-10-27T10:56:40.896+0200    INFO    instance/beat.go:495    filebeat stopped.
2021-10-27T10:56:40.896+0200    ERROR   instance/beat.go:992    Exiting: Failed to start crawler: starting input failed: Error while initializing input: neither queue_url, bucket_arn nor non_aws_bucket_name were provided, input aws-s3 will stop accessing config

@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Oct 27, 2021
@mergify
Copy link
Contributor

mergify bot commented Oct 27, 2021

This pull request does not have a backport label. Could you fix it @aspacca? 🙏
To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-v./d./d./d is the label to automatically backport to the 7./d branch. /d is the digit

NOTE: backport-skip has been added to this pull request.

@mergify mergify bot added the backport-skip Skip notification from the automated backport with mergify label Oct 27, 2021
@elasticmachine
Copy link
Collaborator

elasticmachine commented Oct 27, 2021

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Duration: 100 min 4 sec

❕ Flaky test report

No test was executed to be analysed.

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

  • /package : Generate the packages and run the E2E tests.

  • /beats-tester : Run the installation tests with beats-tester.

@aspacca aspacca merged commit 2a1a0ca into elastic:master Oct 28, 2021
@aspacca aspacca added the Team:Integrations Label for the Integrations team label Oct 28, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations (Team:Integrations)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Oct 28, 2021
Icedroid pushed a commit to Icedroid/beats that referenced this pull request Nov 1, 2021
…elastic#28666)

* not setting queue_url bucket_arn or non_aws_bucket_name returns error
@aspacca aspacca added the backport-v8.0.0 Automated backport with mergify label Nov 11, 2021
@mergify mergify bot removed the backport-skip Skip notification from the automated backport with mergify label Nov 11, 2021
mergify bot pushed a commit that referenced this pull request Nov 11, 2021
…#28666)

* not setting queue_url bucket_arn or non_aws_bucket_name returns error

(cherry picked from commit 2a1a0ca)
aspacca pushed a commit that referenced this pull request Nov 11, 2021
…#28666) (#28929)

* not setting queue_url bucket_arn or non_aws_bucket_name returns error

(cherry picked from commit 2a1a0ca)

Co-authored-by: Andrea Spacca <andrea.spacca@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-v8.0.0 Automated backport with mergify Team:Integrations Label for the Integrations team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants