-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Actor TryGetStateAsync()
/ GetStateAsync()
` is returning stale / previous state
#8538
Comments
Just tested this on runtime 1.14.4 (scheduler reminders feature off) and this is working as expected. Could this be a runtime regression in 1.15? |
@olitomlinson I don't think so.. to my knowledge, unless it's implementing its own cache for batch pooling or the like, the runtime has no knowledge of the SDK cache. It's implemented entirely at the SDK level and on the SDK, it hasn't seen updates since last year (to add TTL support) and again for another year or two before then (for reentrancy support). |
The runtime doesn't do any sort of caching |
Without changing the dotnet SDK version (from latest 1.15 RC), if I downgrade the runtime from 1.15 RC18 to 1.14.4 and turn off scheduled reminders features, it works as expected. That points to this being a runtime issue, no? |
Not necessarily. Can you try to use the API directly (not through the SDK) and report what state you're getting? Also, scheduler reminders data in 1.15 is incompatible with 1.14 so any test should start with a clean state store. |
TryGetStateAsync()
is returning stale / previous stateTryGetStateAsync()
/ GetStateAsync()
` is returning stale / previous state
@olitomlinson do you have actor reentrance enabled? |
@yaron2 nothing explicit in my code, so what ever is the OOTB default |
Can you provide a snippet of your code here? |
We tested this and couldn't reproduce.
cc @artursouza |
Hey all! Thanks for the great write up of the issue 🙂 |
@JoshVanL Can this be closed as completed? |
Runtime 1.15.0-rc15
SDK 1.15.0-rc.04
Expected Behavior
Update : I think this is related to state operations that are performed within the context of a Reminder.
When a call is made to
this.StateManager.TryGetStateAsync()
then I expect the newest/current data to be retrieved.Actual Behavior
When a call is made to
this.StateManager.TryGetStateAsync()
then it is retrieving a cached/previous/stale version of the state.However, if I use the Actor HTTP API to retrieve the same state key, I can see the new/current state returned as expected
If I then kill the dapr/app process, and restart it, the Actor will now log out the correct state
Steps to Reproduce the Problem
Release Note
RELEASE NOTE:
The text was updated successfully, but these errors were encountered: