You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
dreamorosi opened this issue
Jul 5, 2023
· 2 comments
· Fixed by #1583
Assignees
Labels
commonsThis item relates to the Commons UtilitycompletedThis item is complete and has been merged/shippedinternalPRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.)
In #1577, #1575, and #1567 we have added logic that appends a user agent to AWS SDK requests by leveraging the middleware stack of the AWS SDK v3. The current setup however does not take in account the fact that customers might pass us the same client more than once (i.e. create a client > instrument it with Tracer > pass it to Parameters / Idempotency).
Why is this needed?
The current implementation will log a warning that informs the user that Powertools was not able to apply the middleware, this could be misleading.
Which area does this relate to?
Other
Solution
We should make sure that this case is handled correctly by either: 1/ making the operation idempotent (like the X-Ray SDK itself does when instrumenting), 2/ appending the second user agent (like suggested here), 3/ converting operation to a no-op if the middleware is already there.
Should this be considered in other Powertools for AWS Lambda languages? i.e. Python, Java, and .NET
Future readers
Please react with 👍 and your use case to help us understand customer demand.
The text was updated successfully, but these errors were encountered:
dreamorosi
added
internal
PRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.)
discussing
The issue needs to be discussed, elaborated, or refined
commons
This item relates to the Commons Utility
labels
Jul 5, 2023
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.
commonsThis item relates to the Commons UtilitycompletedThis item is complete and has been merged/shippedinternalPRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.)
Summary
In #1577, #1575, and #1567 we have added logic that appends a user agent to AWS SDK requests by leveraging the middleware stack of the AWS SDK v3. The current setup however does not take in account the fact that customers might pass us the same client more than once (i.e. create a client > instrument it with Tracer > pass it to Parameters / Idempotency).
Why is this needed?
The current implementation will log a warning that informs the user that Powertools was not able to apply the middleware, this could be misleading.
Which area does this relate to?
Other
Solution
We should make sure that this case is handled correctly by either: 1/ making the operation idempotent (like the X-Ray SDK itself does when instrumenting), 2/ appending the second user agent (like suggested here), 3/ converting operation to a no-op if the middleware is already there.
Acknowledgment
Future readers
Please react with 👍 and your use case to help us understand customer demand.
The text was updated successfully, but these errors were encountered: