microsoft / durabletask-mssql

Microsoft SQL storage provider for Durable Functions and the Durable Task Framework
MIT License
85 stars 32 forks source link

Non-Deterministic workflow detected #211

Open bhugot opened 3 months ago

bhugot commented 3 months ago

Hello,

We met this following error since Microsoft.DurableTask.SqlServer.AzureFunctions 1.2.2 : Non-Deterministic workflow detected: A previous execution of this orchestration scheduled an activity task with sequence ID 0 and name 'SharedOperationsFunctions_CheckOperationStatus' (version ''), but the current replay execution hasn't (yet?) scheduled this task. Was a change made to the orchestrator code after this instance had already started running?

Note that we also use "Microsoft.Data.SqlClient" Version="5.2.0"

Another rewind seems to fix it

cgillum commented 3 months ago

@bhugot did you make any changes to your orchestrator code between the time it started and the time you upgraded to the v1.2.2 package? This exception normally happens when non-backwards compatible code changes are made that cause the existing history in the DB to no longer match the code.

bhugot commented 3 months ago

Nope I did not that's why I posted this here :)

cgillum commented 3 months ago

Just to confirm, is SharedOperationsFunctions_CheckOperationStatus the first task that gets scheduled in your orchestration?

bhugot commented 3 months ago

Yes it is