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
{{ message }}
Repository navigation
admin replicate resync status --json prints nothing #49
Version: mcli RELEASE.2026-10-18T00-00-00Z, same code on main; server silo RELEASE.2026-10-18T00-00-00Z.
What happens
While a resync is running, mcli admin replicate resync status <site1> <site2> --json exits with code 0 and prints nothing. With --debug only GET /minio/admin/v3/site-replication/info and GET /minio/admin/v3/info are sent, and the metrics request is never made.
Without --json the command needs a terminal (could not open a new TTY otherwise). So in scripts the resync status can only be read through script -qfc.
Cause
In mainAdminReplicationResyncStatus the metrics stream is read in a goroutine (L106), and JSON messages are printed from it (L112). In JSON mode ui.Run() is skipped (L130), so the function returns at L137 right away, and the process exits before the goroutine sends the request.
Suggested fix
In JSON mode, read client.Metrics synchronously (or wait for the goroutine) and stop once SiteResync.Complete() is true.
JSON mode now consumes the metrics stream synchronously without requiring a TTY. It preserves the existing JSON structure, streams Pending/Ongoing samples, and prints the complete Completed, Canceled, or Failed event before stopping the subscription, even when the server keeps the connection open.
A successfully retrieved terminal task state exits with code 0, including Canceled/Failed. HTTP/transport errors, malformed JSON, and unexpected EOF before a terminal event report an error and exit with code 1. User interruption behavior is preserved.
Regression coverage includes both root-level and command-level --json, streamed samples and final-event preservation, all three terminal states, buffered trailing data, HTTP 403, invalid JSON, and interrupted streams. The original implementation fails the regression; the fix passes. Joint #48/#49 regression tests under the race detector, all-package tests, lint/vet, repository checks, make install, and built-binary checks for TTY behavior and signal exits pass.
Activity
Merge fix for site resync JSON status (#49)
Vonng commentedon Oct 26, 2026
Fixed in b5c81bcf, merged into
mainby 18ea0a1a after the #48 fix.JSON mode now consumes the metrics stream synchronously without requiring a TTY. It preserves the existing JSON structure, streams Pending/Ongoing samples, and prints the complete Completed, Canceled, or Failed event before stopping the subscription, even when the server keeps the connection open.
A successfully retrieved terminal task state exits with code 0, including Canceled/Failed. HTTP/transport errors, malformed JSON, and unexpected EOF before a terminal event report an error and exit with code 1. User interruption behavior is preserved.
Regression coverage includes both root-level and command-level
--json, streamed samples and final-event preservation, all three terminal states, buffered trailing data, HTTP 403, invalid JSON, and interrupted streams. The original implementation fails the regression; the fix passes. Joint #48/#49 regression tests under the race detector, all-package tests, lint/vet, repository checks,make install, and built-binary checks for TTY behavior and signal exits pass.GitHub CI passed for the merged commit: Linux/macOS/Windows tests, including the SILO functional suite on Linux, cross-compilation, vulnerability analysis, and release pipeline validation.
This fix will ship in the next release cycle. It is fixed in
mainbut is not yet included in a published release. Closing as completed.