A late acknowledgement from an expired attempt can overwrite the retry attempt
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 45/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Área
- backend, distributed-systems
Línea de trabajo
Start with acknowledge.lua, then trace the lease-expiry retry flow and the worker_ids data mentioned in the issue. Reproduce the sequence where an expired attempt is requeued and a newer attempt reacquires the task. Done means a late acknowledgement from the old attempt cannot remove, publish for, or delete state belonging to the newer attempt.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Found by the SuperJoe review of the lease-expiry retry patch (4ec9068..d5a1fdb).
acknowledge.lua identifies an in-flight attempt only by its membership in the running set:
local removed = redis.call('ZREM', KEYS[1], ARGV[1])
if removed == 0 then
return 0 -- Task already reaped, skip
end
The reaper requeues a task after its lease expires. A second attempt then acquires the same task ID and the entry exists again. A late acknowledgement from the original attempt finds the entry and wins. It does three things:
- It removes the running entry of the second attempt.
- It publishes the result of the first attempt.
- It removes the task hash (
DEL KEYS[3]) that the second attempt still uses.
The second attempt continues to run with its state removed. When it finishes, its acknowledgement is a no operation and the backend discards its result. worker_ids already records which worker holds which attempt. Fencing on the acquiring worker or on an attempt token can correct this.
This error is not the same as the claim race in #71. #71 guards the decision of the broker. This error is the acknowledgement of the worker that arrives after a requeue.
- Lenguaje dominante
- Python
- Estrellas
- 19
- Forks
- 1
- Merge medio
- 9 h 46 min
- PR fusionados (30 d)
- 17
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin 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 codingjoe/threadmill
-
bug real side quest
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
codingjoe/threadmill#78 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug real
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
codingjoe/threadmill#73 ·
Los mantenedores suelen responder en 1 día
-
perf real
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
codingjoe/threadmill#74 ·
Los mantenedores suelen responder en 1 día
-
bug real
Dificultad 4/5 3-5 días Aptitud para principiantes 64/100
codingjoe/threadmill#71 ·
Los mantenedores suelen responder en 1 día
-
perf real
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
codingjoe/threadmill#67 ·
Los mantenedores suelen responder en 1 día
Todos los issues de codingjoe/threadmill
Issues similares
-
Dificultad 1/5 1-3 horas Aptitud para principiantes 85/100
pytest-dev/pluggy#757 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 1-3 horas Aptitud para principiantes 85/100
NousResearch/hermes-agent#134960 ·
Los mantenedores suelen responder en 1 día
-
HTML backend: `<br>` leaks the internal sentinel U+E000 into list items, headings and captionsPosiblemente ocupada @morten-lagabote la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
docling-project/docling#4671 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
Los mantenedores suelen responder en 1 día
-
good first issue hacktoberfest infra
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día