microsoft / durabletask-mssql

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

Delete all payload data on ContinueAsNew #102

Closed cgillum closed 2 years ago

cgillum commented 2 years ago

Resolves https://github.com/microsoft/durabletask-mssql/issues/100

The previous logic deleted payload data that was associated with the rows in the History table. In theory, this should "work" because there shouldn't be any payload data (besides custom status) that doesn't have an associated record in the History table. However, it seems that this isn't necessarily the case, or that we're losing track of certain payload IDs over time.

Regardless of the root cause for the previous issue, it makes sense to just purge all runtime data as part of ContinueAsNew. This PR does exactly that, ensuring that we can't run into this kind of problem in the future.