Integration / Apache Pulsar Interview questions
What is the difference between Shared and Exclusive subscriptions?
An Exclusive subscription allows exactly one consumer at a time; a second consumer attempting to attach with the same subscription name is rejected, and the single active consumer receives every message in strict order.
A Shared subscription allows many consumers to attach simultaneously, with messages round-robined across whichever consumers are currently connected - maximizing horizontal scalability of consumption but giving up any ordering guarantee across the topic.
Exclusive suits use cases needing strict single-consumer ordering; Shared suits use cases needing maximum throughput where message order between different consumers doesn't matter.
More Related questions...