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] resource tags map should be compatible with short or whole resource id #20385

Merged
merged 3 commits into from
Aug 18, 2020

Conversation

kwinstonix
Copy link
Contributor

@kwinstonix kwinstonix commented Jul 31, 2020

  • Bug

What does this PR do?

fix resource tags in metircbeat aws cloudwatch module. more detail has be explained in #20326

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.

How to test this PR locally

  1. metricbeat aws module config
metricbeat.modules:
  - module: aws
    aws_partition: aws
    period: 300s
    access_key_id: 'your key'
    secret_access_key: 'your key'
    regions:
      - ap-northeast-2
    metricsets:
      - cloudwatch
    metrics:
      - namespace: AWS/ApplicationELB
        statistic: ['Minimum']
        name: ['HealthyHostCount']
        #tags.resource_type_filter: elasticloadbalancing   # for verion 7.x
        resource_type: elasticloadbalancing     # for version 8.0
  1. set AWS ELB TargetGroup tags

  2. run metricbeat, aws.tags field in event should contain both LoadBalancer and TargetGroup tags

Related issues

@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 Jul 31, 2020
@kwinstonix kwinstonix marked this pull request as ready for review July 31, 2020 15:40
@elasticmachine
Copy link
Collaborator

elasticmachine commented Jul 31, 2020

💚 Build Succeeded

Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: [kaiyan-sheng commented: jenkins run the tests]

  • Start Time: 2020-08-18T14:27:36.126+0000

  • Duration: 50 min 35 sec

Test stats 🧪

Test Results
Failed 0
Passed 561
Skipped 48
Total 609

@kwinstonix
Copy link
Contributor Author

@kaiyan-sheng , could you help me review this ? 😊

@kaiyan-sheng kaiyan-sheng self-assigned this Jul 31, 2020
@kaiyan-sheng kaiyan-sheng added needs_backport PR is waiting to be backported to other branches. review Team:Platforms Label for the Integrations - Platforms team labels Jul 31, 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 Jul 31, 2020
@kaiyan-sheng
Copy link
Contributor

Hi @kwinstonix ! SORRY for the delay on reviewing this PR 😂 Overall it looks good! I only added one small comment. Also could you rebase this PR please? Thank you!

@kwinstonix kwinstonix force-pushed the fix_targetgroup_tags branch from d839d58 to 970b6dc Compare August 18, 2020 12:54
@kwinstonix
Copy link
Contributor Author

The PR is rebased on master

@kaiyan-sheng
Copy link
Contributor

jenkins run the tests

@kaiyan-sheng kaiyan-sheng merged commit 3ef1811 into elastic:master Aug 18, 2020
@kaiyan-sheng kaiyan-sheng added v7.10.0 and removed needs_backport PR is waiting to be backported to other branches. labels Aug 18, 2020
kaiyan-sheng added a commit that referenced this pull request Aug 19, 2020
…le resource id (#20385) (#20668)

* resource tags map should be compatible with short or whole resource identifier (#20326)

(cherry picked from commit 3ef1811)

Co-authored-by: martin <kwinstonix@users.noreply.github.com>
kaiyan-sheng added a commit that referenced this pull request Aug 19, 2020
…le resource id (#20385) (#20670)

* resource tags map should be compatible with short or whole resource identifier (#20326)

(cherry picked from commit 3ef1811)

Co-authored-by: martin <kwinstonix@users.noreply.github.com>
melchiormoulin pushed a commit to melchiormoulin/beats that referenced this pull request Oct 14, 2020
…le resource id (elastic#20385)

* resource tags map should be compatible with short or whole resource identifier (elastic#20326)
leweafan pushed a commit to leweafan/beats that referenced this pull request Apr 28, 2023
…le resource id (elastic#20385) (elastic#20670)

* resource tags map should be compatible with short or whole resource identifier (elastic#20326)

(cherry picked from commit 4e8f09d)

Co-authored-by: martin <kwinstonix@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
review Team:Platforms Label for the Integrations - Platforms team v7.9.1 v7.10.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[MetricBeat] [AWS] events can't set TargetGroup tags
3 participants