rdhabalia commented on a change in pull request #2259: Fix: set
subscription-type based on message ordering
URL: https://github.com/apache/incubator-pulsar/pull/2259#discussion_r206642127
##########
File path:
pulsar-client-tools/src/main/java/org/apache/pulsar/admin/cli/CmdFunctions.java
##########
@@ -560,24 +565,10 @@ protected FunctionDetails convert(FunctionConfig
functionConfig)
sourceSpecBuilder.setTopicsPattern(functionConfig.getTopicsPattern());
}
- // Set subscription type based on processing semantics
- if (functionConfig.getProcessingGuarantees() != null) {
Review comment:
> It is a better user experience if the user just specify a processing
guarantee and subscription is automatically set for them
Processing-guarantee generally implies how to ack the message and
retain-ordering describes how to consume message. Therefore, if
processing-guarantee is `ATMOST_ONCE ` it means, we want to ack the message
immediately no-matter what result is and `ATMOST_ONCE` can be used with SHARED
or FAILOVER subscription both (means with or without ordering feature). So,
generally processing-guarantee and ordering play separate role in terms of
consuming and processing the message.
> If a user specifies a processing guarantee of effectively once, the
subscription by default should be Failover
hmm.. yes, that make sense. I will make that change.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services