<@U078Y59KC3B> we are planning to use Apache Pulsa...
# ask-ai
s
@RunLLM we are planning to use Apache Pulsar as a replacement for Google Pub/Sub. We are only using Shared or Key_Shared subscription types. The total number of topics in the cluster will not exceed 100 and we are planning to use a single tenant and namespace for all of them. What are the most important Pulsar configurations that we need to set?
r
It seems likely that for your use case (Shared/Key_Shared subscriptions, ≤100 topics, single tenant/namespace), the most important Pulsar configurations are: - Subscription and consumer limits: Ensure
maxConsumersPerSubscription
and
maxSubscriptionsPerTopic
are set high enough for your expected concurrency (source). - Unacknowledged message limits: Tune
maxUnackedMessagesPerConsumer
and
maxUnackedMessagesPerSubscription
to avoid broker memory issues, especially with Key_Shared (source, source). - Retention policy: By default, Pulsar deletes acknowledged messages and topics with no subscriptions. Set a retention policy if you need to retain data after consumption or when no subscriptions exist (source, source). - Inactive topic deletion: Consider disabling or tuning
brokerDeleteInactiveTopicsEnable
and related settings to prevent unexpected topic deletion (source, source). - Receiver queue size: For fine-grained control over consumer memory and throughput, adjust
receiverQueueSize
per consumer (source). Would you like more detail on any of these configuration areas? Sources: - pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java - Pulsar as a message queue - https://github.com/apache/pulsar/issues/21045 - https://pulsar.apache.org/docs/3.2.x/cookbooks-retention-expiry - https://docs.streamnative.io/docs/migrating-to-streamnative#Manage%20Billing 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.