dapr / dapr/dotnet-sdk

Is 'TrySaveStateAsync's throwing on 412 response an intended behaviour?

Open
#1,028 1 comment 0 reactions 0 assignees View on GitHub
area/client/state kind/bug
Dominant language
C#
Stars
1.2k
Forks
378
Avg merge
1d 22h
Merged PRs (30d)
5

Description

Hello
I'm just started using Dapr and found this really odd that the method 'TrySaveStateAsync' is throwing and not simply returning false when it faces newer etag in db. I'm using Cosmos db in local emulator, and here's how I tested it(I know that code on the screen should read new value before re-trying, just wanted to test the behaviour):
![image](https://user-images.githubusercontent.com/15693079/217864036-30a0e691-c308-485f-bf7a-8cc5065fe486.png)
Is that intended or am I doing something wrong here?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.