Module: Rdkafka::Defaults

Defined in:
lib/rdkafka/defaults.rb

Overview

Provides default timeout and configuration values used throughout the library.

These constants standardize timing values across consumers, producers, and admin clients. Values are specified in milliseconds (ms) unless otherwise noted.

Constant Summary collapse

CONSUMER_COMMITTED_TIMEOUT_MS =

Consumer timeout for fetching committed offsets

See Also:

2_000
CONSUMER_QUERY_WATERMARK_TIMEOUT_MS =

Consumer timeout for querying watermark offsets

1_000
CONSUMER_LAG_TIMEOUT_MS =

Consumer timeout for lag calculations

See Also:

1_000
CONSUMER_OFFSETS_FOR_TIMES_TIMEOUT_MS =

Consumer timeout for offset-by-timestamp lookups

1_000
CONSUMER_POLL_TIMEOUT_MS =

Consumer timeout for poll operations (used in each iteration)

See Also:

250
CONSUMER_SEEK_TIMEOUT_MS =

Consumer timeout for seek operations (0 = non-blocking)

See Also:

0
CONSUMER_EVENTS_POLL_TIMEOUT_MS =

Consumer timeout for events_poll (0 = non-blocking async)

0
PRODUCER_FLUSH_TIMEOUT_MS =

Producer timeout for flush operations

See Also:

5_000
PRODUCER_PURGE_FLUSH_TIMEOUT_MS =

Producer timeout for flush during purge

See Also:

100
PRODUCER_PURGE_SLEEP_INTERVAL_MS =

Sleep interval used in producer purge loop

See Also:

1
PRODUCER_SEND_OFFSETS_TIMEOUT_MS =

Timeout for transactional send_offsets_to_transaction

5_000
METADATA_TIMEOUT_MS =

Default timeout for metadata requests

2_000
METADATA_MAX_RETRIES =

Maximum retries for metadata requests on transient errors

10
METADATA_RETRY_BACKOFF_BASE_MS =

Base backoff time for metadata retry (100ms = 0.1s)

100
HANDLE_WAIT_TIMEOUT_MS =

Default wait timeout for operation handles

60_000
NATIVE_KAFKA_POLL_TIMEOUT_MS =

Polling interval for NativeKafka background thread

100
NATIVE_KAFKA_SYNCHRONIZE_SLEEP_INTERVAL_MS =

Sleep interval used in NativeKafka#synchronize wait loop

10
PARTITIONS_COUNT_CACHE_TTL_MS =

TTL for partitions count cache entries (30 seconds)

30_000