Skip to content
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

fix(core): serialize duration as strings #5630

Merged
merged 1 commit into from
Oct 28, 2024

Conversation

loicmathieu
Copy link
Member

Fixes #5615

Since Jackson 2.10, to serialize duration as string we need to switch WRITE_DURATIONS_AS_TIMESTAMPS off as it no longuer use WRITE_DATES_AS_TIMESTAMPS. I tested and an old flow with a duration as timestamp is still readable so this is a backward compatible change.

@loicmathieu loicmathieu force-pushed the fix/duration-serialization branch 3 times, most recently from 1632d86 to 9161807 Compare October 28, 2024 13:47
Fixes #5615

Since Jackson 2.10, to serialize duration as string we need to switch WRITE_DURATIONS_AS_TIMESTAMPS off as it no longuer use WRITE_DATES_AS_TIMESTAMPS.
I tested and an old flow with a duration as timestamp is still readable so this is a backward compatible change.

But for the State duration, we still need to serialize it as a number as the database expect a number
@loicmathieu loicmathieu force-pushed the fix/duration-serialization branch from 9161807 to 63d70ac Compare October 28, 2024 14:01
Copy link

sonarcloud bot commented Oct 28, 2024

@loicmathieu loicmathieu merged commit 557eb81 into develop Oct 28, 2024
9 checks passed
@loicmathieu loicmathieu deleted the fix/duration-serialization branch October 28, 2024 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Duration is not correctly deserialized with Property v2 default value
1 participant