Jay Kahrman created KAFKA-6427:
----------------------------------
Summary: Inconsistent exception type from KafkaConsumer.position
Key: KAFKA-6427
URL: https://issues.apache.org/jira/browse/KAFKA-6427
Project: Kafka
Issue Type: Bug
Components: consumer
Reporter: Jay Kahrman
Priority: Trivial
If KafkaConsumer.position is called with a partition that the consumer isn't
assigned, it throws an IllegalArgumentException. All other APIs throw an
IllegalStateException when the consumer tries to act on a partition that is not
assigned to the consumer.
Looking at the implementation, if it weren't for subscription test and
IllegalArgumentException thrown at the beginning of KafkaConsumer.position, the
very next line would throw an IllegalStateException anyway.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)