Azure / durabletask

Durable Task Framework allows users to write long running persistent workflows in C# using the async/await capabilities.
Apache License 2.0
1.47k stars 287 forks source link

Honor DataConverter when creating JsonConverters #1089

Closed davidmrdavid closed 1 month ago

davidmrdavid commented 1 month ago

In this PR (https://github.com/Azure/durabletask/pull/503) we introduced the ability to use a DataContractConverter when de-/serializing to Json. However, in this PR (https://github.com/Azure/durabletask/pull/775) we moved the instantiation of the JsonConverter to occur before the DataConverter is specified, which means the converter is ignored at de-/serialization time.

This PR fixes that by moving the JsonConverter instantiation to after the DataConverter is provided.

Open question: why did the unit tests in (https://github.com/Azure/durabletask/pull/503) not catch this regression?