golang/oauth2: retrieve token before setting ticker to avoid initial delay#775
Conversation
|
This PR (HEAD: ab82c5c) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/oauth2/+/664596. Important tips:
|
|
Message from Gopher Robot: Patch Set 1: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/664596. |
|
Message from Gopher Robot: Patch Set 1: Congratulations on opening your first change. Thank you for your contribution! Next steps: Most changes in the Go project go through a few rounds of revision. This can be Please don’t reply on this GitHub thread. Visit golang.org/cl/664596. |
|
Message from Sean Liao: Patch Set 3: (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/664596. |
This patch modifies the DeviceAccessToken function to avoid
an unnecessary delay before the first token request is made.
Previously, the function waited for the first interval duration
before making the initial call to retrieveToken. This behavior
causes delay.
This change introduces an immediate initial call to retrieveToken
before entering the ticker loop. Subsequent polling continues to honor
the server-specified interval, as expected.