Skip to content

Periodically warn for long-pending workers - #113

Merged
Nina-mvH merged 6 commits into
mainfrom
17-enhance-pipeline-logging
Aug 13, 2026
Merged

Periodically warn for long-pending workers#113
Nina-mvH merged 6 commits into
mainfrom
17-enhance-pipeline-logging

Conversation

@Nina-mvH

@Nina-mvH Nina-mvH commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Updates the pipeline log to:

  1. Log the number of files staged, completed, and failed upon pipeline termination
  2. Log when worker(s) have been pending for more than 10, 20, 30, ... minutes. In Enhance pipeline logging #17, this was intended to be a warning, but I just made it info level since nothing is technically wrong. This can be easily updated.

Ref #17

@Nina-mvH Nina-mvH linked an issue Aug 11, 2026 that may be closed by this pull request
@Nina-mvH
Nina-mvH requested a review from yoonspark August 11, 2026 19:04

@yoonspark yoonspark left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looking good, but needs some updates. Please see the comments below.

Comment thread src/tigerflow/tasks/utils.py Outdated
Comment thread src/tigerflow/pipeline.py
Comment on lines +153 to +157
# Track how long each currently-pending worker job has been pending,
# and the last 10-minute threshold logged for it, so warnings repeat
# every 10 minutes instead of flooding every poll cycle
self._worker_pending_since: dict[str, dict[int, float]] = defaultdict(dict)
self._worker_pending_alerted: dict[str, dict[int, int]] = defaultdict(dict)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should eventually track these two states together they always pair up for a given pending worker. But the refactor can be rolled into a greater one that involves centralization of all task state tracking (e.g., use TaskState dataclass). Ok as is now.

Comment thread src/tigerflow/pipeline.py Outdated
Comment thread src/tigerflow/pipeline.py Outdated
Comment thread src/tigerflow/pipeline.py Outdated
Comment thread tests/integration/pipeline/test_task_supervision.py Outdated
@Nina-mvH
Nina-mvH requested a review from yoonspark August 13, 2026 15:01

@yoonspark yoonspark left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left two optional suggestions — take as you see fit. Both non-blocking, the PR is approved.

Comment thread src/tigerflow/pipeline.py Outdated
Comment thread docs/mkdocs/guides/configuration.md
@Nina-mvH
Nina-mvH merged commit 991bc34 into main Aug 13, 2026
8 checks passed
@Nina-mvH
Nina-mvH deleted the 17-enhance-pipeline-logging branch August 13, 2026 19:36
@Nina-mvH Nina-mvH changed the title Log pipeline summary at termination and pending time for long-pending workers Periodically warn for long-pending workers Aug 13, 2026
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.

Enhance pipeline logging

2 participants