Skip to content

Conversation

@adelajaworowska
Copy link

@adelajaworowska adelajaworowska commented Dec 19, 2025

Fixes debezium/dbz#1499

MySQL allows the storage of 'zero-year' dates such as 0000-07-15. Currently, the library throws an invalidDateAndTimeRepresentation exception when encountering these values.

I would like the library to support these dates by converting them to a Unix timestamp (epoch-based) instead of failing.

- uses: ./.github/actions/setup-java
- name: Cache Maven packages
uses: actions/cache@v1
uses: actions/cache@v4
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this is not related to the MySQL issue, let's remove this and apply this in a separate PR, please.

Copy link
Author

@adelajaworowska adelajaworowska Jan 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense - removed and the separate PR is here: #18

@Naros
Copy link
Member

Naros commented Jan 5, 2026

Please raise an issue in https://github.com/debezium/dbz and prefix your commit with debezium/dbz#<issue number> so that this can be tracked.

@adelajaworowska adelajaworowska changed the title Do not return invalidDateAndTimeRepresentation when year 0000 debezium/dbz#1499 Do not return invalidDateAndTimeRepresentation when year 0000 Jan 5, 2026
@Naros
Copy link
Member

Naros commented Jan 6, 2026

❌ Developer Certificate of Origin (DCO) check failed.

Hi @adelajaworowska, please sign off all commits with:

git commit -s

If pull request commits are not signed off, the pull request cannot be merged. For more information about why this is required, please see our blog about contribution requirement changes.

@adelajaworowska adelajaworowska force-pushed the support-deserializing-year-0000 branch from 1040cdf to 6e0355f Compare January 6, 2026 20:04
@adelajaworowska
Copy link
Author

Thank you @Naros for your comments. I applied changes and created the issue as you asked.
Please let me know what you think about this enhancement PR.

@adelajaworowska adelajaworowska requested a review from Naros January 6, 2026 20:38
@adelajaworowska adelajaworowska marked this pull request as draft January 7, 2026 12:52
Copy link

@jpechane jpechane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@adelajaworowska LGTM, thanks. Could you please add sign-off to the commit (see DCO requirement) and undraft the PR? I'll merge it then.

@adelajaworowska adelajaworowska marked this pull request as ready for review January 8, 2026 09:45
@adelajaworowska
Copy link
Author

@jpechane thank you for the approval. I undrafted the PR and I the commit is signed-off. Please proceed with merging

@adelajaworowska
Copy link
Author

@jpechane I see two build failures:

  • deprecated version of actions/cache: v1 - I created a separate PR with upgrade that should fix it: debezium/dbz#1515 update workflow to use v4 action/cache #18
  • 'buffer overflow detected' - could you please help me with that one? I wouldn't like to change more than is necessary in your setup. From what I researched, changing ubuntu-latest to some older version in yml file or switching to testcontainers could help. What do you think?

@jpechane jpechane merged commit d3f55a8 into debezium:main Jan 9, 2026
1 of 3 checks passed
@jpechane
Copy link

jpechane commented Jan 9, 2026

@adelajaworowska I tested the fix on MySQL 8 locally. If you'd have spare cycles and by able to rewrite MysqlOnetimeServer to use testContainers then it would be extremely helpful for the project.

@adelajaworowska
Copy link
Author

@jpechane thank you!
Do you know when a version with this fix will be released?

@jpechane
Copy link

jpechane commented Jan 9, 2026

I intend to merge #17 on Monday (this will require changes in Debezium too) and then I'll do release right away.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Do not fail on 'zero-year' dates in MySQL

3 participants