Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Fetching from a non-leader replica is an opt-in feature. We propose to add a second configuration "replica.selection.policy" to indicate whether the "consumer should take the preferred replica selected by the broker or to use the leader as usual.

Configuration NameValid ValuesDefault Value
rack.id<nullable string>null
replica.selection.policyleader, preferredleader

Broker API 

We will expose a new plugin interface configured through the "replica.selector.class" configuration  that allows users to provide custom logic to determine the preferred replica to fetch from.

Configuration NameValid ValuesDefault Value
replica.selector.classclass name of ReplicaSelector implementationnull

The ReplicaSelector interface is provided below:

...