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

Fix Redis EntraId Token Refresh #3632

Merged
merged 1 commit into from
Dec 16, 2024

Conversation

shivamkm07
Copy link
Contributor

Description

When authenticating using EntraId Authentication for Azure Cache for Redis, the token needs to be refreshed before the token expires as mentioned here: #3088 (comment)

However, the context being passed to the background routine gets cancelled once the component initialization is done (or timedout for which the default value is 5s) and so auth token is never refreshed once it expires: https://github.com/dapr/dapr/blob/6c488fdf7d2995d074413c875fc2e3fb4134a33b/pkg/runtime/processor/components.go#L215

This PR removes the dependency on initContext so that goroutine keeps running in the background.

Issue reference

We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.

Please reference the issue this PR will close: #3554

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

Signed-off-by: Shivam Kumar <shivamkumar@microsoft.com>
@yaron2 yaron2 merged commit fc8636d into dapr:main Dec 16, 2024
89 of 90 checks passed
@marcduiker
Copy link
Contributor

@holopin-bot @shivamkm07 Thank you Shivam!

Copy link

holopin-bot bot commented Jan 10, 2025

Congratulations @shivamkm07, the maintainer of this repository has issued you a badge! Here it is: https://holopin.io/claim/cm5qy5a5c20360cmqar3803uu

This badge can only be claimed by you, so make sure that your GitHub account is linked to your Holopin account. You can manage those preferences here: https://holopin.io/account.
Or if you're new to Holopin, you can simply sign up with GitHub, which will do the trick!

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.

Redis Entra Id connection stops working after 24hours
3 participants