Skip to content

Commit e2e0d96

Browse files
committed
Add test for confluentinc#294 (get_watermark_offsets)
1 parent 6328cd8 commit e2e0d96

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

examples/integration_test.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -420,8 +420,15 @@ def verify_consumer():
420420
# Create consumer
421421
c = confluent_kafka.Consumer(**conf)
422422

423+
def print_wmark(consumer, parts):
424+
# Verify #294: get_watermark_offsets() should not fail on the first call
425+
# This is really a librdkafka issue.
426+
for p in parts:
427+
wmarks = consumer.get_watermark_offsets(parts[0])
428+
print('Watermarks for %s: %s' % (p, wmarks))
429+
423430
# Subscribe to a list of topics
424-
c.subscribe([topic])
431+
c.subscribe([topic], on_assign=print_wmark)
425432

426433
max_msgcnt = 100
427434
msgcnt = 0

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy