Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adjust for RefreshInterval not influencing AutomaticRefreshInterval. #2870

Merged
merged 3 commits into from
Oct 4, 2024

Conversation

brentschmaltz
Copy link
Member

Removed last instance of RefreshInterval influencing AutomaticRefreshInterval.

Remove dead code in ConfigurationManager.
There was code inside a null check that would not get executed, it was removed.

@brentschmaltz brentschmaltz requested a review from a team as a code owner October 3, 2024 21:04
@pmaytak
Copy link
Contributor

pmaytak commented Oct 3, 2024

The test is failing

  Failed Microsoft.IdentityModel.Protocols.OpenIdConnect.Tests.ConfigurationManagerTests.BootstrapRefreshIntervalTest [16 ms]
  Error Message:
   Microsoft.IdentityModel.TestUtils.TestException : Microsoft.IdentityModel.Protocols.OpenIdConnect.Tests.ConfigurationManagerTests.BootstrapRefreshIntervalTest

ConfigurationManager._syncAfter: '10/4/2024 9:15:42 AM +00:00' should equal '1/1/0001 12:00:00 AM +00:00'.

  Stack Trace:
     at Microsoft.IdentityModel.TestUtils.TestUtilities.AssertFailIfErrors(String testId, List`1 errors) in D:\a\_work\1\s\test\Microsoft.IdentityModel.TestUtils\TestUtilities.cs:line 371
   at Microsoft.IdentityModel.TestUtils.TestUtilities.AssertFailIfErrors(CompareContext context) in D:\a\_work\1\s\test\Microsoft.IdentityModel.TestUtils\TestUtilities.cs:line 352
   at Microsoft.IdentityModel.Protocols.OpenIdConnect.Tests.ConfigurationManagerTests.<BootstrapRefreshIntervalTest>d__7.MoveNext() in D:\a\_work\1\s\test\Microsoft.IdentityModel.Protocols.OpenIdConnect.Tests\ConfigurationManagerTests.cs:line 262
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

Add random % of AutomaticRefreshInterval to avoid spike in trafic in all cases
@brentschmaltz brentschmaltz force-pushed the brentsch/RequestRefresh branch from 3b5de98 to dcb785c Compare October 3, 2024 23:49
@brentschmaltz brentschmaltz force-pushed the brentsch/RequestRefresh branch from d6777c7 to e9f4fc3 Compare October 4, 2024 23:23
@brentschmaltz brentschmaltz merged commit 6771a49 into dev Oct 4, 2024
6 checks passed
@pmaytak pmaytak linked an issue Oct 5, 2024 that may be closed by this pull request
1 task
@brentschmaltz brentschmaltz deleted the brentsch/RequestRefresh branch October 23, 2024 21:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] Starvation: AAD Token Validation
5 participants