An idle partition's active segment never seals, so its data never expires
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- rust
- Área
- backend, distributed-systems
Línea de trabajo
Read Segment::is_expired in core/partitions/src/segment.rs, remove_sealed_segments_up_to in core/partitions/src/iggy_partition.rs, and the tiered storage RFC section linked in the issue. The issue leaves the solution open and describes why independent replica timers break segment placement, so first work out how a replicated RollSegment operation fits the existing control path. Done means idle active segments can seal without new batches and then participate in retention, compression, and offloading.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Description
A partition that stops receiving messages keeps its active segment open forever, and retention only ever acts on sealed segments. Segment::is_expired returns false for anything unsealed (there is a test for it unsealed_segment_is_never_expired), and remove_sealed_segments_up_to skips the active segment. So an idle partition holds that segment's data indefinitely, no matter what message_expiry or max_topic_size say. Segments it sealed before going idle still expire normally; it is the final partly filled one that never becomes eligible.
This came out of the discussion in #4402, which proposes a time ceiling on a segment's span but evaluates it on append and scopes idle partitions out. That split is the reason for a separate issue: a partition that still receives messages will eventually evaluate a trigger, whether that trigger is the current size check or a time check. A partition receiving nothing never evaluates one at all.
Where it shows up:
- a decommissioned topic leaves every partition sitting on a partly filled segment that never seals and never expires
- the same happens inside a live topic when traffic skews, since a partition that stops receiving keys is idle whether or not the topic is
- an unsealed segment also cannot be compressed or offloaded, so this blocks tiering for those partitions
Affected area / component
Iggy server
Proposed solution
Left open.
Whatever closes this has to fire without an arriving batch, so it cannot be evaluated in the append path. The candidate raised in the tiered storage RFC is a replicated time roll: the primary appends a RollSegment control operation and every replica seals at that operation.
Alternatives considered
- Each replica rolling on its own timer. This does not work: segment boundaries have to be a function of the batches, and
SegmentState::reserveruns on every replica, so a localnow()would place the same batch differently on different replicas and fail the placement check invalidate_segment_prefix.
Contribution
- I'm willing to submit a pull request to implement this feature
Good first issue
- I think this could be a good first issue for a new contributor
- Lenguaje dominante
- Rust
- Estrellas
- 5.2k
- Forks
- 502
- Merge medio
- 3 d 4 h
- PR fusionados (30 d)
- 157
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de apache/iggy
-
Go examples: add a message envelope producer and consumerPosiblemente ocupada @ThunderGod77 la tomó hace 3 días. Abiertogo good first issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
apache/iggy#4694 · 3 comentarios · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
HTTP client treats a consumer group as a plain consumerPosiblemente ocupada @mohitduhan19 la tomó hace 21 días. Abiertobug rust server
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
apache/iggy#4408 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Add the fail-fast connection option to the Rust and Python quick-startsPosiblemente ocupada @QIW9 la tomó hace 8 días. Abiertodocs good first issue
Dificultad 1/5 1-3 horas Aptitud para principiantes 92/100
apache/iggy#4261 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
-
bug python sdk
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
apache/iggy#3748 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug(partitions): a_removal_cut_short_leaves_the_marker_in_place panics when tests run as rootPosiblemente ocupada @coding-by-sea la tomó hoy. Abiertobug CI/CD
apache/iggy#4753 · 1 asignado ·
Los mantenedores suelen responder en 1 día
Todos los issues de apache/iggy
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 2 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
nervosnetwork/fiber#1723 ·
Los mantenedores suelen responder en 2 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 69/100
Los mantenedores suelen responder en 1 día
-
needs triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 71/100
pbakaus/impeccable#1314 ·
Los mantenedores suelen responder en 1 día
-
marmite skill: `curl ... | sh` is the first install method, bypassing review and integrity checksAbierto
Dificultad 1/5 1-3 horas Aptitud para principiantes 78/100
rochacbruno/marmite#565 ·