You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/07/11 10:08:36 UTC

[GitHub] [pulsar] coderzc commented on a diff in pull request #16513: [fix][client] Make DeadLetterPolicy deserializable

coderzc commented on code in PR #16513:
URL: https://github.com/apache/pulsar/pull/16513#discussion_r917763080


##########
pulsar-broker/src/test/java/org/apache/pulsar/client/api/DeadLetterTopicTest.java:
##########
@@ -794,4 +795,16 @@ public void testDeadLetterTopicWithInitialSubscriptionAndMultiConsumers() throws
         otherConsumer.close();
         consumer.close();
     }
+
+    @Test
+    public void testDeadLetterPolicyDeserialize() throws Exception {
+        ConsumerBuilder<String> consumerBuilder = pulsarClient.newConsumer(Schema.STRING);
+        DeadLetterPolicy policy =
+                DeadLetterPolicy.builder().deadLetterTopic("a").retryLetterTopic("a").initialSubscriptionName("a")
+                        .maxRedeliverCount(1).build();
+        consumerBuilder.deadLetterPolicy(policy);

Review Comment:
   I want test DeadLetterPolicy 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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org