Skip to content

[AWS] [Billing] Document GetCostAndUsage API limitation - #9290

Merged
6 commits merged into
mainfrom
unknown repository
Apr 8, 2024
Merged

[AWS] [Billing] Document GetCostAndUsage API limitation#9290
6 commits merged into
mainfrom
unknown repository

Conversation

@ghost

@ghost ghost commented Mar 6, 2024

Copy link
Copy Markdown

Overview

This change aims to document the limitation of the GetCostAndUsage API used by the billing metricset. Since it only allows grouping costs by two groups at once we can end up with duplicated data.

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • I have verified that Kibana version constraints are current according to guidelines.

Author's Checklist

  • [ ]

How to test this PR locally

Related issues

Screenshots

@ghost ghost self-assigned this Mar 6, 2024
@ghost ghost added the Integration:aws AWS label Mar 6, 2024
@elasticmachine

elasticmachine commented Mar 7, 2024

Copy link
Copy Markdown

🚀 Benchmarks report

To see the full report comment with /test benchmark fullreport

@elastic-sonarqube

Copy link
Copy Markdown

Quality Gate passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No Coverage information No data about Coverage
No Duplication information No data about Duplication

See analysis details on SonarQube

@ghost
ghost marked this pull request as ready for review March 7, 2024 10:02
@ghost
ghost requested review from a team as code owners March 7, 2024 10:02
@ghost
ghost requested a review from agithomas March 7, 2024 10:02
Comment thread packages/aws/_dev/build/docs/billing.md Outdated

When you want to group by a combination of several tags and dimensions, like `SERVICE` along with various tags (e.g., `team`, `project`, `aws:createdBy`), you might see duplicated data. This happens because of a [limitation](https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_GetCostAndUsage.html) with the `GetCostAndUsage` API, which only allows grouping costs by two different groups.

To avoid data duplication, it's recommended to group data using two groups at once.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Is there a problem in using just one member in the group?

I guess, by group you meant - one tag + one dimension / two tags / two dimensions.

It would be best to explain this a little bit more, i think

It may be best to rephrase recommended to group data using two groups at once.. The word group when used in two different context makes it more confusing.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

To avoid data duplication, it's recommended to aggregate data using a combination of two attributes, which can be either: one tag and one dimension, two tags or two dimensions. do you think this makes more sense?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yes, this improves clarity.

@elastic-sonarqube

Copy link
Copy Markdown

Quality Gate passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No Coverage information No data about Coverage
No Duplication information No data about Duplication

See analysis details on SonarQube

@elasticmachine

Copy link
Copy Markdown

💚 Build Succeeded

History

cc @gpop63

@ishleenk17

Copy link
Copy Markdown
Member

@gpop63 : Are we waiting for something here?

@ghost
ghost merged commit a13cf83 into elastic:main Apr 8, 2024
@elasticmachine

Copy link
Copy Markdown

Package aws - 2.14.1 containing this change is available at https://epr.elastic.co/search?package=aws

@BenB196

BenB196 commented Apr 8, 2024

Copy link
Copy Markdown
Contributor

Just an FYI,

which can be either: one tag and one dimension, two tags or two dimensions.

two tags or two dimensions.

This part isn't currently possible with Elastic's AWS integration. elastic/beats#38755 attempts to resolve this, but this doc changes might be confusing to users.

This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document the limitations of AWS Billing integration in supporting multiple tags and dimensions.

7 participants