Repository navigation
CLOUDP-472112: mongocli om standby-clusters lag — report standby replication lag - #147
Merged
Merged
Conversation
tonyclarkemonogodb
requested review from
danielblanco96
and removed request for
a team
November 9, 2026 20:37
| _, err := fmt.Fprintf(o.OutWriter, "%s: NA\n", o.componentID()) | ||
| return err | ||
| } | ||
| for _, s := range status.ShardStatus { |
Contributor
There was a problem hiding this comment.
Maybe we can sort these by the lag values, for convenience.
Contributor
Author
There was a problem hiding this comment.
On the fence about this. For now I am inclined to leave it in the same order as the json. But we can always update this later if it feels better sorted.
aarushtalwar
approved these changes
Nov 10, 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.
Ticket
CLOUDP-472112
Description
New subcommand
mongocli om standby-clusters lag: reports the standby cluster's replication lag by reading the Cluster Status Object (cluster_status_v1.bson, the contract from CLOUDP-471131) directly from the object store — no Ops Manager API — so it stays available when OM is down.--shards) — received-but-unapplied oplog relayed from the object'slagSeconds(never recomputed client-side); the drain work promotion completes.now − MCTS): the standby's freshest applied op was committed that many seconds ago.-o jsonprints the full contract document (unchanged field names). The three-line shape is constant across healthy / partially-published / uninitialized objects (NA/not available yetfill-ins).Notes
.gitignore*.imladdition.