diff options
-rw-r--r-- | kafka/consumer/fetcher.py | 4 | ||||
-rw-r--r-- | kafka/consumer/group.py | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/kafka/consumer/fetcher.py b/kafka/consumer/fetcher.py index ddf9d6f..8f25561 100644 --- a/kafka/consumer/fetcher.py +++ b/kafka/consumer/fetcher.py @@ -267,14 +267,14 @@ class Fetcher(six.Iterator): AssertionError: if used with iterator (incompatible) Returns: - dict: {TopicPartition: deque([messages])} + dict: {TopicPartition: [messages]} """ assert self._iterator is None, ( 'fetched_records is incompatible with message iterator') if self._subscriptions.needs_partition_assignment: return {} - drained = collections.defaultdict(collections.deque) + drained = collections.defaultdict(list) self._raise_if_offset_out_of_range() self._raise_if_unauthorized_topics() self._raise_if_record_too_large() diff --git a/kafka/consumer/group.py b/kafka/consumer/group.py index cea2e1c..33563b8 100644 --- a/kafka/consumer/group.py +++ b/kafka/consumer/group.py @@ -343,7 +343,7 @@ class KafkaConsumer(six.Iterator): records that are available now. Must not be negative. Default: 0 Returns: - dict: topic to deque of records since the last fetch for the + dict: topic to list of records since the last fetch for the subscribed list of topics and partitions """ assert timeout_ms >= 0, 'Timeout must not be negative' @@ -377,7 +377,7 @@ class KafkaConsumer(six.Iterator): timeout_ms (int): The maximum time in milliseconds to block Returns: - dict: map of topic to deque of records (may be empty) + dict: map of topic to list of records (may be empty) """ # TODO: Sub-requests should take into account the poll timeout (KAFKA-1894) self._coordinator.ensure_coordinator_known() |