Open maximemg opened 1 year ago
Yes, CustomMessageRoute is not supported yet.
I was wondering if there's a way to ensure messages will be received by the same consumer in a key shared sub ? Because so far I could not achieve that with keys.
Is there any ETA for the CustomMessageRoute ?
I was wondering if there's a way to ensure messages will be received by the same consumer in a key shared sub ? Because so far I could not achieve that with keys.
// Create a producer and disabled batch
const producer = await client.createProducer({
topic: 'persistent://public/default/my-topic',
sendTimeoutMs: 30000,
batchingEnabled: false,
});
// Create a consumer and use KeyShared sub type.
const consumer = await client.subscribe({
topic: 'persistent://public/default/my-topic',
subscription: 'sub1',
subscriptionType: 'KeyShared',
ackTimeoutMs: 10000,
});
Hello,
My goal is to ensure a consumer will always receive key associated messages. But from my tests, on adding/removing consumers there are cases where Pulsar will do a rebalance.
So I think my best shot is to publish to a specific partition and subscribe to this specific partition with my customer.
So what I would do is implement the Message Router interface as explained here. But I could not make it in the Node.js client, as it does not seem to exist.
Will that be implemented in the future ?
Let me know if I'm mistaking or if it's unclear, as I'm pretty new to Apache Pulsar. Thanks for reading.