View Source Elsa.Partitioner behaviour (Elsa.fi v3.2.0)

Behaviour for partitioning messages produced to Kafka.

Link to this section Summary

Types

Partition selected by the partitioning strategy.

The number of partitions for a topic.

Link to this section Types

@type partition() :: non_neg_integer()

Partition selected by the partitioning strategy.

@type partition_count() :: pos_integer()

The number of partitions for a topic.

Link to this section Callbacks

Link to this callback

partition(partition_count, key)

View Source
@callback partition(partition_count(), key :: term()) :: partition()