Skip to content

run/logs: tail >32 array pager via resolog#16

Merged
tawAsh1 merged 1 commit into
mainfrom
feat/resolog-array-pager
Jun 14, 2026
Merged

run/logs: tail >32 array pager via resolog#16
tawAsh1 merged 1 commit into
mainfrom
feat/resolog-array-pager

Conversation

@tawAsh1

@tawAsh1 tawAsh1 commented Jun 14, 2026

Copy link
Copy Markdown
Owner

Final integration step (PR-4). The large-array pager now tails through resolog too — completing the swap of batchkoi's CloudWatch tailing onto resolog.

What changes

For arrays > maxTailedChildren (32), the interactive pager UI is unchanged (windows, arrow keys, raw mode, progress bar), but the fetch moves to resolog:

  • Each visible page runs its own resolog.Tail over windowSources (a Resolution that emits one batch[N] Source per child in the window as its stream appears) + childSink.
  • Switching pages cancels the current window's tail and starts the next.
  • The parallel status loop keeps [STATUS], the progress bar, the final JobDetail and exit-on-FAILED. Off-terminal → progress-only (unchanged).

Why no resolog change

A bounded 32-child window keeps the per-child fan-in under the FilterLogEvents TPS quota, so the "see all children at once" firehose / multi-stream batching is deliberately not built (it would overwhelm output anyway). Paging stays the readable, TPS-safe model. tailOnce now backs only the logs no-follow one-shot dump.

Tests

  • New TestWindowSources (window Source emission incl. labels/streams/group).
  • Existing pager unit tests + array-follow tests green; full -race green; dependency-hygiene gate still clean (no sfn/lambda).

Note on coverage

The interactive pager path needs a TTY, so (as before this PR) it isn't exercised end-to-end in CI; the testable core (windowSources, childSink) is unit-tested.

🤖 Generated with Claude Code

Final integration step. The large-array pager (size > maxTailedChildren) now
tails each visible page through resolog instead of the home-grown GetLogEvents
loop: a per-page resolog.Tail over windowSources (one "batch[N]" Source per
child in the window) + childSink. Switching pages cancels the current window's
tail and starts the next; the parallel status loop keeps [STATUS], the progress
bar, the final JobDetail and exit-on-FAILED. Off-terminal it falls back to
progress-only, as before.

No resolog change needed: a bounded 32-child window keeps the per-child fan-in
under the FilterLogEvents TPS quota, so batching (multi-stream sources) is
deferred. tailOnce now backs only the logs no-follow one-shot dump.

childTail trimmed to {id, stream}. Tests: TestWindowSources (window source
emission); existing pager/array tests green; full -race green.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@tawAsh1 tawAsh1 merged commit 9573190 into main Jun 14, 2026
4 checks passed
@tawAsh1 tawAsh1 deleted the feat/resolog-array-pager branch June 14, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant