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

Feature request: populate middy's request.internal with cleanup function for Metrics #1535

Closed
1 of 2 tasks
dreamorosi opened this issue Jun 21, 2023 · 2 comments · Fixed by #1546
Closed
1 of 2 tasks
Assignees
Labels
completed This item is complete and has been merged/shipped feature-request This item refers to a feature request for an existing or new utility metrics This item relates to the Metrics Utility

Comments

@dreamorosi
Copy link
Contributor

Use case

In the previous release we introduced a new shared function in the commons package that allows Middy middleware authors to call a cleanup function whenever their middleware has to return early. This allows other Powertools utilities that might be present in the Middleware stack to run their cleanup logic.

In the case of Metrics this means flushing any stored metric to avoid delays in the reporting or potential (if unlikely) data loss.

Solution/User Experience

See PoC in the initial feature proposal.

Alternative solutions

No response

Acknowledgment

Future readers

Please react with 👍 and your use case to help us understand customer demand.

@dreamorosi dreamorosi added metrics This item relates to the Metrics Utility feature-request This item refers to a feature request for an existing or new utility confirmed The scope is clear, ready for implementation labels Jun 21, 2023
@dreamorosi dreamorosi self-assigned this Jun 22, 2023
@dreamorosi dreamorosi moved this from Backlog to Working on it in Powertools for AWS Lambda (TypeScript) Jun 22, 2023
@dreamorosi dreamorosi linked a pull request Jun 22, 2023 that will close this issue
9 tasks
@github-project-automation github-project-automation bot moved this from Working on it to Coming soon in Powertools for AWS Lambda (TypeScript) Jun 22, 2023
@github-actions
Copy link
Contributor

⚠️ COMMENT VISIBILITY WARNING ⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

@github-actions github-actions bot added pending-release This item has been merged and will be released soon and removed confirmed The scope is clear, ready for implementation labels Jun 22, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Jun 23, 2023

This is now released under version 1.10.0!

@github-actions github-actions bot added completed This item is complete and has been merged/shipped and removed pending-release This item has been merged and will be released soon labels Jun 23, 2023
@dreamorosi dreamorosi moved this from Coming soon to Shipped in Powertools for AWS Lambda (TypeScript) Jun 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
completed This item is complete and has been merged/shipped feature-request This item refers to a feature request for an existing or new utility metrics This item relates to the Metrics Utility
Projects
1 participant