In Apache Pulsar, the Key_Shared subscription type ensures that messages with the same key are delivered to only one consumer. However, this routing is limited to each topic individually. According to the
Pulsar documentation, messages with the same key are dispatched to the same consumer within the context of a single topic. Therefore, if you have multiple topics, the same key (e.g., "user-123") from different topics will not necessarily be routed to the same consumer. Each topic's messages are handled independently, and the key-based routing applies within the scope of each topic.
Would you like more detail on how Key_Shared subscriptions work or any other aspect of Apache Pulsar?
Sources:
-
Pulsar documentation 👍 0 button 👎 0 button 💡
Hint: Mention @runllm in the thread for followups.