From 540cf6983f6ebee6cb818a0eafc69dafef55b9c5 Mon Sep 17 00:00:00 2001 From: Neil Twigg Date: Mon, 25 Sep 2023 11:19:45 +0100 Subject: [PATCH] Add `observer` to cluster replica info This is to support nats-io/nats-server#4582. Signed-off-by: Neil Twigg --- jsm.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/jsm.go b/jsm.go index 720efe2ee..9de66372d 100644 --- a/jsm.go +++ b/jsm.go @@ -979,11 +979,12 @@ type ClusterInfo struct { // PeerInfo shows information about all the peers in the cluster that // are supporting the stream or consumer. type PeerInfo struct { - Name string `json:"name"` - Current bool `json:"current"` - Offline bool `json:"offline,omitempty"` - Active time.Duration `json:"active"` - Lag uint64 `json:"lag,omitempty"` + Name string `json:"name"` + Current bool `json:"current"` + Observer bool `json:"observer,omitempty"` + Offline bool `json:"offline,omitempty"` + Active time.Duration `json:"active"` + Lag uint64 `json:"lag,omitempty"` } // UpdateStream updates a Stream.