Skip to content

Commit 7d027f6

Browse files
authored
REST Updates (#18)
* Logging * add FuncName() to all errors for better debugging issues Signed-off-by: Keith Russo <[email protected]> * Merge for Publish (#13) * Logging (#11) * add FuncName() to all errors for better debugging issues Signed-off-by: Keith Russo <[email protected]> Signed-off-by: Keith Russo <[email protected]> * Bugfix (#12) * Develop Version * changes removing references to v10 during development and testing Signed-off-by: Keith Russo <[email protected]> * Logging * add FuncName() to all errors for better debugging issues Signed-off-by: Keith Russo <[email protected]> * Update for New Endpoints Signed-off-by: Keith Russo <[email protected]> * Bugfix * fix incorrect http method when adding a guild member role Signed-off-by: Keith Russo <[email protected]> * Updates * update go version to 1.20 * update go.mod deps Signed-off-by: Keith Russo <[email protected]> * Logging fix from merge conflict resolution Signed-off-by: Keith Russo <[email protected]> --------- Signed-off-by: Keith Russo <[email protected]> --------- Signed-off-by: Keith Russo <[email protected]> * Fix v10 import paths Signed-off-by: Keith Russo <[email protected]> * Updates * dep updates * update application.go * (NEW) add application_role_connection_metadata * update to audit_log * permissions helpers for all permissions * auto-moderation updates and endpoints * update channel.go * work on channel_endpoints.go (WIP) Signed-off-by: Keith Russo <[email protected]> * Update logger * migrate dapi wrapper to use nowlive-logging Signed-off-by: Keith Russo <[email protected]> * Qodana Updates & SonarCloud fixes Signed-off-by: Keith Russo <[email protected]> * Updates * moved channel api to channel_endpoints.go * struct updates Signed-off-by: Keith Russo <[email protected]> * Qodana fix Signed-off-by: Keith Russo <[email protected]> * Final updates for current state of DAPI Signed-off-by: Keith Russo <[email protected]> * Qodana updates Signed-off-by: Keith Russo <[email protected]> * Qodana updates Signed-off-by: Keith Russo <[email protected]> * Updates & Context * update deps * add missing oauth2 scope * Qodana update * increase context timeout Signed-off-by: Keith Russo <[email protected]> * HTTP Requests Update * remove the use of context in HTTP requests * use a fixed backoff for retries vs exponential backoff * update User agent version Signed-off-by: Keith Russo <[email protected]> * API Updates * Add undocumented fields in User struct Signed-off-by: Keith Russo <[email protected]> * REST Updates * remove retrier * adjust the timeout up 200ms Signed-off-by: Keith Russo <[email protected]> --------- Signed-off-by: Keith Russo <[email protected]>
1 parent eeeaed8 commit 7d027f6

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

api/rest.go

+2-7
Original file line numberDiff line numberDiff line change
@@ -26,20 +26,15 @@ import (
2626
"strings"
2727
"time"
2828

29-
"github.com/gojek/heimdall/v7"
3029
"github.com/gojek/heimdall/v7/httpclient"
3130
log "github.com/veteran-software/nowlive-logging"
3231
)
3332

3433
//goland:noinspection SpellCheckingInspection
3534
var (
36-
timeout = 1000 * time.Millisecond
35+
timeout = 1200 * time.Millisecond
3736

38-
httpClient = httpclient.NewClient(
39-
httpclient.WithHTTPTimeout(timeout),
40-
httpclient.WithRetryCount(2),
41-
httpclient.WithRetrier(heimdall.NewRetrier(heimdall.NewConstantBackoff(100*time.Millisecond,
42-
500*time.Millisecond))))
37+
httpClient = httpclient.NewClient(httpclient.WithHTTPTimeout(timeout))
4338
)
4439

4540
var (

0 commit comments

Comments
 (0)