Skip to content

Commit

Permalink
fix: timeout duration of Pendo client
Browse files Browse the repository at this point in the history
The timeout was not using correct duration unit as default is
Nanosecond.

So when used with defaults, the request almost immediately timed out.

Signed-off-by: Petr Vobornik <[email protected]>
  • Loading branch information
pvoborni authored and frasertweedale committed Aug 26, 2024
1 parent a103aa5 commit 6a331a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/usecase/client/pendo/pendo_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ func newClient(cfg *config.Config) *pendoClient {
cfg.Clients.PendoRequestTimeoutSecs = 3
}
client := &http.Client{
Timeout: time.Duration(cfg.Clients.PendoRequestTimeoutSecs),
Timeout: time.Duration(cfg.Clients.PendoRequestTimeoutSecs) * time.Second,
}
return &pendoClient{
Config: cfg,
Expand Down

0 comments on commit 6a331a6

Please sign in to comment.