Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface LoadBalancingOptions

Package version

An options bag to configure load balancing settings.

Hierarchy

  • LoadBalancingOptions

Index

Properties

Optional partitionOwnershipExpirationIntervalInMs

partitionOwnershipExpirationIntervalInMs: undefined | number

The length of time a partition claim is valid. Default: 60000

Optional strategy

strategy: "balanced" | "greedy"

Whether to apply a greedy or a more balanced approach when claiming partitions.

  • balanced: The EventHubConsumerClient will take a measured approach to requesting partition ownership when balancing work with other clients, slowly claiming partitions until a stabilized distribution is achieved.

  • greedy: The EventHubConsumerClient will attempt to claim ownership of its fair share of partitions aggressively when balancing work with other clients.

This option is ignored when either:

  • CheckpointStore is not provided to the EventHubConsumerClient.
  • subscribe() is called for a single partition. Default: balanced

Optional updateIntervalInMs

updateIntervalInMs: undefined | number

The length of time between attempts to claim partitions. Default: 10000

Generated using TypeDoc