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

[Metricbeat] Add cloud.account.id into events from aws module #13558

Merged
merged 11 commits into from
Oct 9, 2019
Merged

[Metricbeat] Add cloud.account.id into events from aws module #13558

merged 11 commits into from
Oct 9, 2019

Conversation

kaiyan-sheng
Copy link
Contributor

@kaiyan-sheng kaiyan-sheng commented Sep 9, 2019

This PR is to add the ability to collect cloud.account.id and cloud.account.name into aws module. More user-friendly, account alias(For example: elastic-kaiyan-aws) is preferred than the account id(For example: 123456789).

cloud.account.name can be empty because for aws account, alias is not required.

closes #13551

How to test this:

With this change, if you enable any metricset under aws module and check in Kibana, you should see cloud.account.id in the event. If the account alias is set, then cloud.account.name should exist as well in the new event.

@kaiyan-sheng kaiyan-sheng requested a review from a team as a code owner September 9, 2019 21:28
@kaiyan-sheng kaiyan-sheng self-assigned this Sep 10, 2019
@kaiyan-sheng kaiyan-sheng added Team:Integrations Label for the Integrations team in progress Pull request is currently in progress. Metricbeat Metricbeat labels Sep 10, 2019
Copy link
Contributor

@sayden sayden left a comment

Choose a reason for hiding this comment

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

LGTM. One question. Does it removes completely the ID from the event? I don't see a real need for it but, who knows, maybe it's mandatory for someone.

Ah! And I have to ask for the mandatory new binary size after adding more packages 😬

@kaiyan-sheng
Copy link
Contributor Author

@sayden Thanks for the review 😬 No, it does not remove ID from the event. It only adds a new field for the cloud account. Regarding to the binary size, I'm actually not sure why this time, it added all files under aws/aws-sdk-go-v2/service/iam hmm

@kaiyan-sheng kaiyan-sheng added [zube]: In Review review and removed [zube]: In Progress in progress Pull request is currently in progress. labels Sep 17, 2019
@kaiyan-sheng kaiyan-sheng added the test-plan Add this PR to be manual test plan label Oct 3, 2019
@kaiyan-sheng kaiyan-sheng merged commit f4d3df2 into elastic:master Oct 9, 2019
@kaiyan-sheng kaiyan-sheng deleted the account_id branch October 9, 2019 19:45
@exekias
Copy link
Contributor

exekias commented Oct 10, 2019

sorry for the late comment, just a double check: Do we need to document any added permission for this to work?

@kaiyan-sheng
Copy link
Contributor Author

sorry for the late comment, just a double check: Do we need to document any added permission for this to work?

@exekias You are absolutely right! Yes, two more permissions are needed. I will push a separate PR to add it. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Metricbeat Metricbeat review Team:Integrations Label for the Integrations team test-plan Add this PR to be manual test plan v7.5.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Metricbeat] Investigate on adding AccountID in aws module
4 participants