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

Inconsistent Logging for Tombstone Messages in Elastic Sink Connector #741

Open
AbdelkaderR opened this issue Dec 27, 2023 · 0 comments
Open

Comments

@AbdelkaderR
Copy link

AbdelkaderR commented Dec 27, 2023

reportBadRecord(record, new ConnectException("Cannot write null valued record."));

Hi everyone,
I hope this message finds you well. I am reaching out regarding an issue I encountered while working with the Elastic Sink Connector. Specifically, the problem is related to the handling of tombstone messages in the code.
Upon reviewing the code, I noticed that at line 107, an error message is logged when the connector encounters a tombstone message, irrespective of the configuration set for behavior.on.null.values. According to the current implementation, even if the configuration is set to IGNORE, an error message is still written to the logs. However, I believe the behavior should be consistent with the TombstoneHandler transform, where, if set to Ignore, a DEBUG message is written to the logs instead of an error message.

As per the TombstoneHandler documentation:

  • If set to ignore, the tombstone record is ignored silently, with a DEBUG message written to log.
  • If set to warn, the tombstone record is ignored silently, with a WARN message written to log.
  • If set to fail, the execution fails, a DataException is thrown, and a DEBUG message is written to log.

The current implementation's tendency to log an error message instead of a DEBUG message can potentially impact the connector's performance, especially in scenarios where a large volume of tombstone messages needs to be processed. Writing an error message for each tombstone message introduces unnecessary overhead.

I kindly request a review of this issue and consideration for aligning the logging behavior with the TombstoneHandler transform, ensuring that DEBUG messages are logged when behavior.on.null.values is set to IGNORE.

Thank you for your time and attention to this matter. Please let me know if you require any further information or clarification.

Best regards,
Abdelkader

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

No branches or pull requests

1 participant