cloud-sql-proxy icon indicating copy to clipboard operation
cloud-sql-proxy copied to clipboard

Adjust IAM token refresh buffer to 5 minutes

Open enocom opened this issue 3 years ago • 0 comments

IAM Tokens are refreshed at 5 minutes to expiry on the metadata server (i.e. the /computeMetadata/v1/instance/service-accounts/default/token endpoint).

Currently, we wait until 55 seconds before a token expires before refreshing it. It seems possible that we could bump this buffer up to 5 minutes, or just short of 5 minutes, and still get a fresh token, while leaving more room for retries.

enocom avatar Mar 30 '22 16:03 enocom