KafkaAssignment
Attributes
- Source
- KafkaAssignment.scala
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
Members list
Value members
Abstract methods
Manually assigns the specified list of topic partitions to the consumer.
Manually assigns the specified list of topic partitions to the consumer. This function does not allow for incremental assignment and will replace the previous assignment (if there is one).
Manual topic assignment through this method does not use the consumer's group management functionality. As such, there will be no rebalance operation triggered when group membership or cluster and topic metadata change. Note that it is not possible to use both manual partition assignment with assign
and group assignment with subscribe
.
If auto-commit is enabled, an async commit (based on the old assignment) will be triggered before the new assignment replaces the old one.
To unassign all partitions, use KafkaConsumer#unsubscribe.
Attributes
- See also
-
org.apache.kafka.clients.consumer.KafkaConsumer#assign
- Source
- KafkaAssignment.scala
Manually assigns all partitions for the specified topic to the consumer.
Manually assigns all partitions for the specified topic to the consumer.
Attributes
- Source
- KafkaAssignment.scala
Returns the set of partitions currently assigned to this consumer.
Returns the set of partitions currently assigned to this consumer.
Attributes
- Source
- KafkaAssignment.scala
Stream
where the elements are the set of TopicPartition
s currently assigned to this consumer.
Stream
where the elements are the set of TopicPartition
s currently assigned to this consumer. The stream emits whenever a rebalance changes partition assignments.
Attributes
- Source
- KafkaAssignment.scala
Concrete methods
Manually assigns the specified list of partitions for the specified topic to the consumer.
Manually assigns the specified list of partitions for the specified topic to the consumer. This function does not allow for incremental assignment and will replace the previous assignment (if there is one).
Manual topic assignment through this method does not use the consumer's group management functionality. As such, there will be no rebalance operation triggered when group membership or cluster and topic metadata change. Note that it is not possible to use both manual partition assignment with assign
and group assignment with subscribe
.
If auto-commit is enabled, an async commit (based on the old assignment) will be triggered before the new assignment replaces the old one.
To unassign all partitions, use KafkaConsumer#unsubscribe.
Attributes
- See also
-
org.apache.kafka.clients.consumer.KafkaConsumer#assign
- Source
- KafkaAssignment.scala