ATO-2350: use timestamp to emit metric#7873
Draft
Ryan-Andrews99 wants to merge 3 commits intoATO-2350-add-spot-queued-metricfrom
Draft
ATO-2350: use timestamp to emit metric#7873Ryan-Andrews99 wants to merge 3 commits intoATO-2350-add-spot-queued-metricfrom
Ryan-Andrews99 wants to merge 3 commits intoATO-2350-add-spot-queued-metricfrom
Conversation
Adds SpotQueuedAtMs attribute which will store a Millisecond unix timestamp which represents when a SPOT request has been queued. We will use this at SPOT response handler to caclulate the response time of SPOT I have made this a boxed Long,as there are some cases in which SPOT will not be queued (such as in the return code scenario)
We would like to time how long SPOT takes per journey, and to do this we need to persist the timestamp, in milliseconds, of when we queued a SPOT request. We can't do this in metrics becasue it would generate a unique metric with new dimensions per journey. Instead we can store the timestamp on serialising the identity credentials in dynamo. Then we can compare this on SPOT response to get a measure of how long SPOT takes
Now we're storing the queued at timestamp, we can now emit a metric for the latency of SPOT, calculating the difference between now and the time at which the request was queued
|
4112018 to
394af97
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Now we're storing the queued at timestamp, we can now emit a metric for the latency of SPOT, calculating the difference between now and the time at which the request was queued
Wider context of change
What’s changed
Manual testing
Checklist
Related PRs