BewareMyPower commented on code in PR #24020:
URL: https://github.com/apache/pulsar/pull/24020#discussion_r1976835087


##########
pulsar-client-api/src/main/java/org/apache/pulsar/client/api/DeadLetterPolicy.java:
##########
@@ -62,4 +63,16 @@ public class DeadLetterPolicy implements Serializable {
      * to be created.
      */
     private String initialSubscriptionName;
+
+    /**
+     * Function to build the producer for the retry letter topic.
+     * The input parameter is the topic name.
+     */
+    private Function<String, ProducerBuilder<byte[]>> 
retryLetterProducerBuilder;
+
+    /**
+     * Function to build the producer for the dead letter topic.
+     * The input parameter is the topic name.
+     */
+    private Function<String, ProducerBuilder<byte[]>> 
deadLetterProducerBuilder;

Review Comment:
   >  so that more context parameters can be added besides the topic name.
   
   It's a good point.
   
   I'm also +1 to `Function<ProducerBuilderContext, ProducerBuilder<byte[]>>`.



-- 
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