Class ShardKey.KeyOrderedKey
java.lang.Object
io.confluent.parallelconsumer.state.ShardKey
io.confluent.parallelconsumer.state.ShardKey.KeyOrderedKey
- Enclosing class:
- ShardKey
-
Nested Class Summary
Nested classes/interfaces inherited from class io.confluent.parallelconsumer.state.ShardKey
ShardKey.KeyOrderedKey, ShardKey.TopicPartitionKey -
Constructor Summary
ConstructorsConstructorDescriptionKeyOrderedKey(org.apache.kafka.clients.consumer.ConsumerRecord<?, ?> rec) KeyOrderedKey(org.apache.kafka.common.TopicPartition topicName, Object key) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleangetKey()The key of the record being referenced.org.apache.kafka.common.TopicPartitionNote: We use just the topic name here, and not the partition, so that if we were to receive records from the same key from the partitions we're assigned, they will be put into the same queue.inthashCode()toString()Methods inherited from class io.confluent.parallelconsumer.state.ShardKey
of, of, ofKey, ofTopicPartition
-
Constructor Details
-
KeyOrderedKey
public KeyOrderedKey(org.apache.kafka.clients.consumer.ConsumerRecord<?, ?> rec) -
KeyOrderedKey
-
-
Method Details
-
getTopicName
public org.apache.kafka.common.TopicPartition getTopicName()Note: We use just the topic name here, and not the partition, so that if we were to receive records from the same key from the partitions we're assigned, they will be put into the same queue. -
getKey
The key of the record being referenced. Nullable if record is produced with a null key. -
toString
-
equals
-
canEqual
-
hashCode
public int hashCode()
-