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

feat(metrics): increase maximum dimensions to 29 #1072

Merged
merged 2 commits into from
Aug 23, 2022

Conversation

sthuber90
Copy link
Contributor

Description of your changes

Amazon added support to up 30 dimensions per metric. In this PR we increase this limit

How to verify this change

Review the code changes and the results of the automated builds.

Related issues, RFCs

Issue number: #1044

PR status

Is this ready for review?: YES
Is it a breaking change?: NO

Checklist

  • My changes meet the tenets criteria
  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • I have made corresponding changes to the examples
  • My changes generate no new warnings
  • The code coverage hasn't decreased
  • I have added tests that prove my change is effective and works
  • New and existing unit tests pass locally and in Github Actions
  • Any dependent changes have been merged and published in downstream module
  • The PR title follows the conventional commit semantics

Breaking change checklist

N/A


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Copy link
Contributor

@dreamorosi dreamorosi left a comment

Choose a reason for hiding this comment

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

Thank you for opening the PR.

I'm going to ask for a review to another maintainer as we have a 2 approvals model for each PR.

Note for the next maintainer: I have run e2e tests and the result was successful:
image

@@ -459,6 +459,7 @@ describe('Class: Metrics', () => {
});

test('Should throw an error if the same metric name is added again with a different unit', ()=> {
expect.assertions(1);
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you please move this assertion at the end of the test? This file specifically is a bit of an outlier, but generally speaking we try to do 1/ Setup, 2/ Action, 3/ Assess

Copy link
Contributor

Choose a reason for hiding this comment

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

I just saw that the assertion is used at the beginning in other test cases of this file, we will be changing this in the context of #163 to make them more uniform to the other two utils.

You can choose to ignore the comment or address it, it won't be a blocker for this PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

As you already said, I added it at the beginning just as it's the case in other tests. If I hadn't seen this, I would have used the fail('reason') before the catch block but that's something to be adressed in the issue that you've referenced

Copy link
Contributor

@ijemmy ijemmy left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for your contribution @sthuber90 :)

@dreamorosi dreamorosi merged commit 7b9a027 into aws-powertools:main Aug 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Increase maximum number of metrics dimension from 10 to 30
3 participants