Replies: 3 comments
-
Are you running into credentials being expired when they shouldn't be? Or were you just looking at the code trying to understand its logic? If it's the former please create an issue so that we can take a look. |
Beta Was this translation helpful? Give feedback.
-
Both actually. We ran into an issue where when the daylight savings happened the token expired when it should not have and it was not refreshed. That lead me to look at the code and saw how PreempExpiryTime is handled and decided to start the discussion before posting an issue so not to waste time for someone to look into it. I will do some tests next week and maybe come back and post an issue. |
Beta Was this translation helpful? Give feedback.
-
I was looking at this and I think, while confusing, the value returned from So, The implementation for Most usages pass zero as the additional preempt expiry and are thus not impacted, but In Please let me know if you see any issues with my train of thought. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
In file
aws-sdk-net/sdk/src/Core/Amazon.Runtime/Credentials/RefreshingAWSCredentials.cs
the method CredentialsRefreshState.GetTimeToLive is supposed to return time to live for the token, but the value will always be greater than the remaining time if PreemptExpiryTime is set to a value greater than TimeSpan.Zero. From my understanding of time to live, the value should never be greater than the Expiration - Now; by this logic the correct formula should be Expiration - Now - PreemptExpiryTime.What am I missing here?
Beta Was this translation helpful? Give feedback.
All reactions