test(observability-proxy): replay the early line into the e2e tail

The background tail goes through the console route and the proxy's
reviews before it subscribes, so the early ingest can land first, and
a tail without start_offset returns only lines written after it
starts. The tail now replays the last minute, which still leaves the
hold and the late-line check meaningful.

Assisted-by: LLM
Signed-off-by: ZverGuy <maximbel2003@gmail.com>
This commit is contained in:
ZverGuy committed 2026-11-10 00:45:06 +07:00
1 parent b1108e836a
commit f775948d2c
1 file changed
+3 -1
@@ -227,8 +227,10 @@ spec:
forward cozy-dashboard cozy-dashboard-console 18080:8080
token=$(k -n tenant-test-logsa create token logs-viewer --duration=10m)
# The tail is not subscribed yet when the next ingest runs, so it
# replays the last minute to include the early line.
timeout 150 curl --silent --no-buffer --header "Authorization: Bearer $token" \
"$CONSOLE$LOGS_A/tail?query=*" > "$tail_out" &
"$CONSOLE$LOGS_A/tail?query=*&start_offset=1m" > "$tail_out" &
tail_pid=$!
ingest tenant-test-logsa e2e-tail-early
ingest tenant-test-logsb e2e-tail-b