Skip to content

Commit

Permalink
fix(run): do not show aggregator status failure too early. SPLAT-624
Browse files Browse the repository at this point in the history
  • Loading branch information
bostrt committed Jun 30, 2022
1 parent 41636de commit b069750
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 4 additions & 0 deletions pkg/run/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package run
import (
"context"
"fmt"
"time"

configv1 "github.com/openshift/api/config/v1"
operatorv1 "github.com/openshift/api/operator/v1"
Expand Down Expand Up @@ -88,6 +89,9 @@ func NewCmdRun() *cobra.Command {
return
}

// Sleep to give status time to appear
time.Sleep(status.StatusInterval)

s := status.NewStatusOptions(o.watch)
err = s.WaitForStatusReport(cmd.Context(), sclient)
if err != nil {
Expand Down
1 change: 0 additions & 1 deletion pkg/status/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,6 @@ func (s *StatusOptions) WaitForStatusReport(ctx context.Context, sclient sonobuo

err = s.Update(sclient)
if err != nil {
// TODO Should the warning be shown to user by default? It can be misleading during startup
log.WithError(err).Warn("error retrieving current aggregator status")
} else if s.Latest.Status != "" {
return true, nil
Expand Down

0 comments on commit b069750

Please sign in to comment.