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

Check AWS ListMetrics API call without giving namespace #14965

Closed
kaiyan-sheng opened this issue Dec 5, 2019 · 4 comments · Fixed by #14971
Closed

Check AWS ListMetrics API call without giving namespace #14965

kaiyan-sheng opened this issue Dec 5, 2019 · 4 comments · Fixed by #14971
Assignees
Labels
in progress Pull request is currently in progress. Metricbeat Metricbeat Team:Integrations Label for the Integrations team

Comments

@kaiyan-sheng
Copy link
Contributor

For cloudwatch metricset, check what happens if namespace is not given when making ListMetrics API call. If we can make ListMetrics API call without giving namespace, then we can make cloudwatch metricset to collect metrics for all available resources.

@kaiyan-sheng kaiyan-sheng added Metricbeat Metricbeat Team:Integrations Label for the Integrations team labels Dec 5, 2019
@kaiyan-sheng kaiyan-sheng self-assigned this Dec 5, 2019
@kaiyan-sheng
Copy link
Contributor Author

@exekias @sorantis I tried to run cloudwatch metricset with namespace: "*" and ListMetrics API did what we expected: it returned all metrics exists in that AWS account and was able to use to obtain statistical data.

- module: aws
  period: 300s
  credential_profile_name: elastic-test
  metricsets:
    - cloudwatch
  metrics:
    - namespace: "*"
      statistic: ["Average"]

Here is what cloudwatch metricset collected:
Screen Shot 2019-12-05 at 1 42 46 PM

The problem is: statistic and period are defined for all metrics. For example, AWS/Usage metrics should be collected every 1 minute instead of every 5 minutes(data loss in this case). Also some metrics like AWS/Billing, should be collected every 6 hours or 12 hours instead of every 5 minutes(introduced extra cost in this case).

@kaiyan-sheng kaiyan-sheng added the in progress Pull request is currently in progress. label Dec 5, 2019
@kaiyan-sheng
Copy link
Contributor Author

Very small change in the code to enable this: #14971

@sorantis
Copy link
Contributor

sorantis commented Dec 6, 2019

Thanks for checking this @kaiyan-sheng. I think it won't hurt to add this wildcard, as long as we make it explicit in the documentation that the chosen period has certain implications.

@kaiyan-sheng
Copy link
Contributor Author

@sorantis Sounds good, I will update the PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in progress Pull request is currently in progress. Metricbeat Metricbeat Team:Integrations Label for the Integrations team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants