Skip to content

Commit

Permalink
Merge pull request #1475 from grafana/fix-client-timeout
Browse files Browse the repository at this point in the history
fix: time multiplier was not applied if the timeout was in the spec
  • Loading branch information
theSuess authored Mar 26, 2024
2 parents c189d2d + b9b2ea6 commit be90a24
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions controllers/client/grafana_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ func NewGeneratedGrafanaClient(ctx context.Context, c client.Client, grafana *v1
timeout = 0
}
} else {
timeout = time.Second * 10
timeout = 10
}

credentials, err := getAdminCredentials(ctx, c, grafana)
Expand All @@ -194,7 +194,7 @@ func NewGeneratedGrafanaClient(ctx context.Context, c client.Client, grafana *v1

client := &http.Client{
Transport: transport,
Timeout: timeout,
Timeout: timeout * time.Second,
}

cfg := &genapi.TransportConfig{
Expand Down

0 comments on commit be90a24

Please sign in to comment.