Skip to content

Commit c02d30f

Browse files
committed
Remove maybe_wait_for_producer_id test debug statements; PID => producer_id
1 parent ab3440b commit c02d30f

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

Diff for: kafka/producer/sender.py

+1-4
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def run_once(self):
134134
for expired_batch in expired_batches:
135135
self._sensors.record_errors(expired_batch.topic_partition.topic, expired_batch.record_count)
136136

137-
# Reset the PID if an expired batch has previously been sent to the broker.
137+
# Reset the producer_id if an expired batch has previously been sent to the broker.
138138
# See the documentation of `TransactionState.reset_producer_id` to understand why
139139
# we need to reset the producer id here.
140140
if self._transaction_state and any([batch.in_retry() for batch in expired_batches]):
@@ -195,9 +195,7 @@ def add_topic(self, topic):
195195
self.wakeup()
196196

197197
def _maybe_wait_for_producer_id(self):
198-
log.debug("_maybe_wait_for_producer_id")
199198
if not self._transaction_state:
200-
log.debug("_maybe_wait_for_producer_id: no transaction_state...")
201199
return
202200

203201
while not self._transaction_state.has_pid():
@@ -230,7 +228,6 @@ def _maybe_wait_for_producer_id(self):
230228
except Errors.RequestTimedOutError:
231229
log.debug("InitProducerId request to node %s timed out", node_id)
232230
time.sleep(self.config['retry_backoff_ms'] / 1000)
233-
log.debug("_maybe_wait_for_producer_id: ok: %s", self._transaction_state.producer_id_and_epoch)
234231

235232
def _failed_produce(self, batches, node_id, error):
236233
log.error("Error sending produce request to node %d: %s", node_id, error) # trace

0 commit comments

Comments
 (0)