fifottl queue entries with an explicit ttl get stuck in an odd state
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 35/100
Línea de trabajo
Empieza con el proyecto de reproducción enlazado y su docker/Dockerfile; después ejecuta npm i, build.sh en Docker y npm run test. Inspecciona las llamadas concurrentes a queue.tube.test_buffer:take, put y ack, especialmente el caso de ttl explícito. Se considera terminado cuando las entradas no quedan con ttl 0 y un next_event grande, y la reproducción ya no deja tareas expiradas incorrectamente que no estén disponibles mediante take.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
when this syntax is used to put data in the buffer
queue.tube.test_buffer:put(data, {ttr=60, ttl=15768000000000000})
You end up with entries that have a ttl of 0 and a large next_event time
issue after the test fails the buffer has entries in a state where the ttl is 0, but next event is large [[select "task_id" from "test_buffer" where "ttl" = 0;]] the entries are not returned from take as they are expired, but they should not have expired
using docker image tarantool/tarantool:2.8.4
and a nodejs client
Place tarantool --version output here.
Tarantool 2.8.4-0-g47e6bd362
Target: Linux-x86_64-RelWithDebInfo
Build options: cmake . -DCMAKE_INSTALL_PREFIX=/usr/local -DENABLE_BACKTRACE=ON
Compiler: /usr/bin/cc /usr/bin/c++
C_FLAGS: -fexceptions -funwind-tables -fno-omit-frame-pointer -fno-stack-protector -fno-common -fopenmp -msse2 -std=c11 -Wall -Wextra -Wno-strict-aliasing -Wno-char-subscripts -Wno-format-truncation -Wno-gnu-alignof-expression -fno-gnu89-inline -Wno-cast-function-type
CXX_FLAGS: -fexceptions -funwind-tables -fno-omit-frame-pointer -fno-stack-protector -fno-common -fopenmp -msse2 -std=c++11 -Wall -Wextra -Wno-strict-aliasing -Wno-char-subscripts -Wno-format-truncation -Wno-invalid-offsetof -Wno-gnu-alignof-expression -Wno-cast-function-type
Steps to reproduce
see the project at
https://github.com/mannnick24/tarantool-fifottl-explicit-ttl/blob/main/docker/Dockerfile
this code uses node tarantool connection to concurrently call queue.tube.test_buffer:take, queue.tube.test_buffer:put and queue.tube.test_buffer:ack
How to run:
npm i
build.sh (in docker)
npm run test
Actual behavior
after the test fails the buffer has entries in a state where the ttl is 0, but next event is large [[select "task_id" from "test_buffer" where "ttl" = 0;]] the entries are not returned from take as they are expired, but they should not have expired
e.g. box.execute([[select "task_id", "status", "created", "ttr", "ttl", "next_event" from "el_buffer" where "ttl" = 0 limit 20;]])
metadata:
name: task_id type: unsigned
name: status type: string
name: created type: unsigned
name: ttr type: unsigned
name: ttl type: unsigned
name: next_event type: unsigned rows:
[4, 'r', 1662662470225835, 60000000, 0, 18446744073709551615]
Expected behavior
the buffer would be empty
- Lenguaje dominante
- Lua
- Estrellas
- 244
- Forks
- 56
- Merge medio
- 6 d 8 h
- PR fusionados (30 d)
- 1
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
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 tarantool/queue
-
tube:grant() is not documented Abiertodocumentation good first issue
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
-
*ttl drivers: TTL branch dereferences delete() result without a nil check, killing the fiber Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 76/100
-
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
-
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
-
1sp bug teamE
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
Todos los issues de tarantool/queue
Issues similares
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
LandSandBoat/server#11579 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
ArchiveTeam/sinavideo-grab#7 · 3 reacciones ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
mailcow/mailcow-dockerized#7480 ·
-
Mapper: a failed area image export crashes Mudlet if the profile closed while it was running Abiertomapper bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100