View Source PulsarEx (PulsarEx v0.15.0)
Summary
Functions
Count active (started) consumers for cluster/tenant/namespace/subscription, cheaply - a single Registry scan, no per-consumer calls
List the distinct clusters with started consumers for tenant/namespace/subscription, so callers don't have to know a worker's configured cluster ahead of time. Uses ConsumerIDRegistry rather than ConsumerReadyRegistry so a cluster is still discovered while its consumers are down/reconnecting, not just while healthy.
Desired, active, and ready consumer counts for cluster/tenant/namespace/subscription - desired comes from the consumer manager, active/ready from local registries
List all the consumers on default cluster
List all the consumers for cluster
List all the consumers for cluster on a specific topic
List all the consumers for cluster on a specific topic with specific subscription
Publish a message to pulsar, create a pool of producers if not yet created
Count consumers that have reached the :READY state for cluster/tenant/namespace/subscription
Start consumer from a fully quantified topic
Start consumers with topic pattern
Stop consumers with fully quantified topic
Stop consumers with topic pattern
Types
Functions
Count active (started) consumers for cluster/tenant/namespace/subscription, cheaply - a single Registry scan, no per-consumer calls
List the distinct clusters with started consumers for tenant/namespace/subscription, so callers don't have to know a worker's configured cluster ahead of time. Uses ConsumerIDRegistry rather than ConsumerReadyRegistry so a cluster is still discovered while its consumers are down/reconnecting, not just while healthy.
Desired, active, and ready consumer counts for cluster/tenant/namespace/subscription - desired comes from the consumer manager, active/ready from local registries
List all the consumers on default cluster
List all the consumers for cluster
List all the consumers for cluster on a specific topic
List all the consumers for cluster on a specific topic with specific subscription
produce(topic_name, payload, message_opts \\ [], producer_opts \\ [])
View Source@spec produce(String.t(), binary(), keyword(), keyword()) :: {:ok, %PulsarEx.Proto.MessageIdData{ __unknown_fields__: term(), ack_set: term(), batch_index: term(), batch_size: term(), entryId: term(), ledgerId: term(), partition: term() }} | {:error, any()}
Publish a message to pulsar, create a pool of producers if not yet created
Count consumers that have reached the :READY state for cluster/tenant/namespace/subscription
@spec start_consumer(topic_name(), subscription(), module(), keyword()) :: :ok | {:error, any()}
Start consumer from a fully quantified topic
start_consumer(tenant, namespace, topic, subscription, module, opts)
View Source@spec start_consumer( tenant(), namespace(), topic(), subscription(), module(), keyword() ) :: :ok | {:error, any()}
Start consumers with topic pattern
@spec stop_consumer(topic(), subscription()) :: :ok
Stop consumers with fully quantified topic
@spec stop_consumer(tenant(), namespace(), topic(), subscription()) :: :ok
Stop consumers with topic pattern