Skip to content

Commit

Permalink
Merge pull request #1187 from nats-io/neil/mirrorreport
Browse files Browse the repository at this point in the history
Fix columns for mirrors under `Replication Report`
  • Loading branch information
ripienaar authored Nov 22, 2024
2 parents e79126f + d302d97 commit f16976c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cli/stream_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -1477,7 +1477,7 @@ func (c *streamCmd) reportAction(_ *fisk.ParseContext) error {

func (c *streamCmd) renderReplication(stats []streamStat) {
table := newTableWriter("Replication Report")
table.AddHeaders("Stream", "Kind", "API Prefix", "Source Stream", "Filters and Transforms", "Active", "Lag", "Error")
table.AddHeaders("Stream", "Kind", "API Prefix", "Source Stream", "Filters and Transforms", "Seen", "Lag", "Error")

for _, s := range stats {
if len(s.Sources) == 0 && s.Mirror == nil {
Expand All @@ -1496,9 +1496,9 @@ func (c *streamCmd) renderReplication(stats []streamStat) {
}

if c.reportRaw {
table.AddRow(s.Name, "Mirror", eApiPrefix, s.Mirror.Name, "", "", s.Mirror.Active, s.Mirror.Lag, apierr)
table.AddRow(s.Name, "Mirror", eApiPrefix, s.Mirror.Name, "", s.Mirror.Active, s.Mirror.Lag, apierr)
} else {
table.AddRow(s.Name, "Mirror", eApiPrefix, s.Mirror.Name, "", "", f(s.Mirror.Active), f(s.Mirror.Lag), apierr)
table.AddRow(s.Name, "Mirror", eApiPrefix, s.Mirror.Name, "", f(s.Mirror.Active), f(s.Mirror.Lag), apierr)
}
}

Expand Down

0 comments on commit f16976c

Please sign in to comment.