Legacy IZkStateListenerI0ItecImpl causes zombie participants by discarding session IDs
@LZD-PratyushBhatt ya está trabajando en esto.
Desde el 11/8/2025.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 45/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Estancado
- Stack tecnológico
- java
- Área
- distributed-systems
Línea de trabajo
Localiza el wrapper heredado IZkStateListenerI0ItecImpl y DedicateZkClient.handleNewSession, y luego rastrea cómo los eventos en cola de ZkEventThread pasan los ID de sesión al manejo de LiveInstance. Reproduce el problema con dos ID de sesión falsos y verifica que cada evento use su contexto de sesión original sin dejar los handlers restablecidos ni crear instancias LiveInstance duplicadas.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Describe the bug
Helix participants can enter a "zombie" state where they appear healthy in ZooKeeper but are functionally disconnected from cluster operations, unable to process state transition messages. This occurs due to a critical flaw in the legacy compatibility wrapper IZkStateListenerI0ItecImpl that completely ignores session ID parameters when processing ZooKeeper session events.
When the single-threaded ZkEventThread becomes blocked (e.g., during long-running FINALIZE operations), multiple SyncConnected events accumulate in the event queue. Once processing resumes, these events are handled in FIFO order, but the legacy wrapper discards the original session ID from each queued event and falls back to using the current active session ID via getSessionId(). This causes session events originally queued for older sessions to be processed using the context of the most recent session, violating the intended event processing timeline.
The result is catastrophic: the first misprocessed event successfully creates a LiveInstance for the current session, but all subsequent events in the backlog attempt to create LiveInstances for the same current session and fail with "already has a live-instance" exceptions. Each failed attempt partially resets the participant's message handlers (setting _ready = false) but never completes the re-initialization process, leaving the participant in a broken state where it cannot process any state transition messages despite appearing active to the Helix controller.
To Reproduce
Create a DedicateZkClient, pass any fake sessionID in handleNewSession. It will totally discard that sessionID and will use the current active zk connection session ID and will all the processing based on that. Trigger another handleNewSession event with fake sessionID, it will fail to create liveinstance this time, and handlers will be kept in reset state.
Expected behavior
Session events should be processed with their original session context regardless of timing delays. The handleNewSession() method should receive and use the correct session ID that was active when the event was originally queued, ensuring proper FIFO event processing and maintaining participant message handling capabilities.
Additional context
Add any other context about the problem here.
- Lenguaje dominante
- Java
- Estrellas
- 505
- Forks
- 258
- Merge medio
- 4 d 20 h
- PR fusionados (30 d)
- 3
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Sin 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/helix
-
Four TestConstraintBasedAlgorithm tests pass when nothing is thrownPosiblemente ocupada @sharanggupta la tomó hoy. Abierto
Dificultad 1/5 1-3 horas Aptitud para principiantes 85/100
-
Helix ZkClient times out after successful ZooKeeper SASL DIGEST-MD5 authenticationPosiblemente ocupada @adityaanikam la tomó hace 43 días. Abiertobug
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
-
NPE in canCompleteSwap if path doesn't existsPosiblemente ocupada @waterWang la tomó hace 106 días. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 50/100
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
Todos los issues de apache/helix
Issues similares
-
bug documentation good first issue help wanted priority low size XS
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
martin-francois/symphony-trello#1351 ·
Los mantenedores suelen responder en 1 día
-
Add test coverage for ConvertUtil.parseDate() with NULL inputPosiblemente ocupada @mirajul-mollah7 la tomó hoy. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 78/100
eclipse-sw360/sw360#4792 · 1 comentario ·
Los mantenedores suelen responder en 3 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
aws/aws-emulator#30 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 4 días
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100