mlyahmed commented on issue #9585:
URL: https://github.com/apache/pulsar/issues/9585#issuecomment-781881135


   Actually the first need is to qualify the current behavior if is it correct 
or must be reviewed.
   
   When the consumer is subscribed to a pattern it is behavior is correct since 
is does not recreate the topics and when topics are created or deleted it 
changes its subscriptions automatically (discovery)
   
   the "odd" behavior is noticed when it is subscribed to a partitioned topic:
   
   - When the topic is deleted forcefully with auto-creation, it recreates 
regular topics with the same names as the deleted partitions and not as 
partitioned topic. Also it does not subscribe to these topics. Is it correct 
doing so ? Naively, I would suggest that it must recreate a partitioned topic 
as it was.
   - When the topic is deleted forcefully with auto-creation disabled, 
         - it detects that and ignores it with error message (See 
MultiTopicsConsumerImpl.subscribeIncreasedTopicPartitions). It treats only the 
case of increasing partitions as the method name suggests.
         - And when the topic is recreated manually:
             -  with the same partitions number ==> it does nothing since it 
compares the number registered in the consumer with the current number of the 
topics partitions.
             - With a bigger partition number ==> it subscribes to the new 
partitions but does not resubscribe to the old ones.
                 ==> is this correct as behavior? Naively, I would suggest that 
the consumer must resubscribe to the new topic automatically or exits, if there 
is no active subscription, to allow an auto-relaunch for example.
   
   Thanks


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

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


Reply via email to