Tim Brooks created KAFKA-2129:
---------------------------------
Summary: Consumer could make multiple concurrent metadata requests
Key: KAFKA-2129
URL: https://issues.apache.org/jira/browse/KAFKA-2129
Project: Kafka
Issue Type: Bug
Components: clients
Reporter: Tim Brooks
Priority: Minor
The NetworkClient's metadataFetchInProgress is neither volatile nor atomic.
This protects against multiple metadata requests being made and is read on
poll() on the NetworkClient. It is written to when a request is initiated.
This is fine for the producer. Which seems to have one thread writing. The
KafkaConsumer's poll() method is synchronized, so there will not be more than
one writer entering from there. However, the NetworkClient's poll() method is
also accessed on the Consumer's partitionsFor() method. Which could be access
by a separate thread.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)