Repository navigation
Track and emit metric for disconnect time from ACS - #4920
Merged
Merged
Conversation
danehlim
force-pushed
the
acs-disconnected-time
branch
from
April 7, 2026 23:51
ebc98df to
b3abb2b
Compare
danehlim
marked this pull request as ready for review
April 8, 2026 19:48
harishxr
approved these changes
Apr 8, 2026
prateekchaudhry
approved these changes
Apr 9, 2026
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.
Summary
Track time ECS Agent last disconnected from ACS and emit as a metric upon reconnecting to ACS which measures how long ECS Agent spent disconnected before reconnecting to ACS.
Implementation details
lastDisconnectedTimefield tosessionstruct. It gets set totime.Now()whenever a disconnection from ACS occursACSSession.ACSDisconnectedDurationmetric and emit whenever ECS Agent reconnects to ACS. The metric captures how long the ECS Agent is disconnected for until it reestablishes a WebSocket connection with ACSTesting
New tests cover the changes: yes (existing tests updated)
Description for the changelog
N/A
Additional Information
Does this PR include breaking model changes? If so, Have you added transformation functions?
No
Does this PR include the addition of new environment variables in the README?
No
Licensing
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.