Skip to content

Conversation

@vsantwana
Copy link

@vsantwana vsantwana commented Dec 29, 2025

What is the purpose of the change

The pull request logs deserialisation errors as debug logs when ignoreParseErrors is set to true.

Brief change log

(for example:)

  • Logs a debug error for deserialisation errors

Verifying this change

Please make sure both new and modified tests in this PR follow the conventions for tests defined in our code quality guide.

This change added tests and can be verified as follows:

  • Added test that validate that when there is a deserialisation error, a debug log is logged

Does this pull request potentially affect one of the following parts:

  • Dependencies (does it add or upgrade a dependency): No
  • The public API, i.e., is any changed class annotated with @Public(Evolving): No
  • The serializers: No
  • The runtime per-record code paths (performance sensitive): No
  • Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: No
  • The S3 file system connector: No

Documentation

  • Does this pull request introduce a new feature? No

@flinkbot
Copy link
Collaborator

flinkbot commented Dec 29, 2025

CI report:

Bot commands The @flinkbot bot supports the following commands:
  • @flinkbot run azure re-run the last Azure build

Copy link
Contributor

@RocMarshal RocMarshal left a comment

Choose a reason for hiding this comment

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

Thanks for the improvement.

Left a few of comments.
PTAL~

@vsantwana
Copy link
Author

Thanks @RocMarshal for the review. I have addressed the comments. PTAL!

@vsantwana
Copy link
Author

@flinkbot run azure

if (!ignoreParseErrors) {
throw new IOException(
format(
"Unknown \"type\" value \"%s\". The Canal JSON message is '%s'",
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: the IOException is the same as the debug content - can we use the same variable?

}

@Test
void testIgnoreParseErrorsLogsDebugMessage() throws Exception {
Copy link
Contributor

@davidradl davidradl Dec 30, 2025

Choose a reason for hiding this comment

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

could you add a test case for fail on missing as well please. This also comes out of JsonParserToRowDataConverters as a JsonParseException.

@github-actions github-actions bot added the community-reviewed PR has been reviewed by the community. label Dec 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-reviewed PR has been reviewed by the community.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants