Skip to content

Commit

Permalink
feat: make default auto.offset.reset earliest (#349)
Browse files Browse the repository at this point in the history
error is undesirable most of the time and is not a good default.
it can cause downtime when doing things like scaling partitions
as the new partitions will error thus crashlooping the consumer.
this happened in inc-702
  • Loading branch information
lynnagara committed Apr 4, 2024
1 parent cbd9367 commit 9c0b0e7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion arroyo/backends/kafka/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def build_kafka_consumer_configuration(
) -> KafkaBrokerConfig:

if auto_offset_reset is None:
auto_offset_reset = "error"
auto_offset_reset = "earliest"

if queued_max_messages_kbytes is None:
queued_max_messages_kbytes = DEFAULT_QUEUED_MAX_MESSAGE_KBYTES
Expand Down
2 changes: 1 addition & 1 deletion rust-arroyo/src/backends/kafka/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ enum KafkaConsumerState {

#[derive(Debug, Clone, Copy, Default)]
pub enum InitialOffset {
#[default]
Earliest,
Latest,
#[default]
Error,
}

Expand Down

0 comments on commit 9c0b0e7

Please sign in to comment.