adam987 opened a new issue, #400:
URL: https://github.com/apache/pulsar-client-node/issues/400

   **pulsar-client** version: 1.12.0
   **Pulsar** version: 4.0.0
   
   We are creating a Pulsar client service that should enable message 
acknowledgment with a previously serialized message ID.
   
   During our tests:
   1. No error is thrown during ID deserialization (calling `toString` on the 
deserialized message ID also returns a valid value);
   2. No error is thrown during message acknowledgment using `acknowledgeId` 
method;
   3. The message that should be acknowledged after the process isn't marked to 
delete by Pulsar and is received again after resubscription when we use the 
deserialized message ID.
   
   This makes the deserialized message ID unusable for acknowledging the 
message. When we use message ID retrieved directly from a received message 
(without serialization/deserialization) acknowledgment by ID works correctly.
   
   Below is a short version of the code that doesn't seem to work even though 
no error is thrown
   
`consumer.acknowledgeId(MessageId.deserialize(message.getMessageId().serialize()))`
   
   Some data (maybe a topic) is probably lost during 
serialization/deserialization, making the deserialized message ID useless. 
However, the fact that the `acknowledgeId` method returns no error seems 
strange.
   
   **Expected behavior:**
   The deserialized message ID should enable acknowledging a message.
   
   I'm also attaching a link to the repo with the error reproduction
   https://github.com/adam987/pulsar-message-id-deserialization


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to