[KAFKA-180] PartialValueStrategy clone key which is not interested Created: 21/Dec/20 Updated: 28/Oct/23 Resolved: 13/Jan/21 |
|
| Status: | Closed |
| Project: | Kafka Connector |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 1.4.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Yj hwang | Assignee: | Ross Lawley |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
The PartialValueStrategy component attempts to clone via BSON parsing on both the key and value of the kafka message. At this time, bson parsing is attempted for the key value, resulting in a parsing error if the key is an unsupported value. This error completely stops consuming messages. I think this is an unintended strategy implementation. PartialValueStrategy should try bson parsing only for the value. For example, kafka's key type is string type. When I try to clone the key, the key is converted to a bson type. But it's just a string, so the conversion(bson parsing) fails. Just cloning the value in PartialValueStrategy is clear and enough. The same goes for PartialKeyStrategy. |
| Comments |
| Comment by Githook User [ 13/Jan/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||
|
Author: {'name': 'Ross Lawley', 'email': 'ross.lawley@gmail.com', 'username': 'rozza'}Message: Fix LazyBsonDocument clone (#46) Clone the LazyBsonDocument and not the unwrapped BsonDocument.
| |||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Ross Lawley [ 12/Jan/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Ross Lawley [ 04/Jan/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||
|
Scheduling for 1.4.0 | |||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Yj hwang [ 22/Dec/20 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||
|
This is my suggestion. If I misunderstood or missed something, please let me know. | |||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Yj hwang [ 21/Dec/20 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||
|
A sample config and the error with the key with `string` type.
| |||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Esha Bhargava [ 21/Dec/20 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||
|
lala7573@gmail.com Thanks for reporting this issue! We'll look into it and get back to you. |