Skip to content

perf(agent): publish normal events off restore path - #355

Draft
hutm wants to merge 1 commit into
ai-dynamo:mainfrom
hutm:review/nonblocking-normal-events
Draft

hutm wants to merge 1 commit into
ai-dynamo:mainfrom
hutm:review/nonblocking-normal-events

Conversation

@hutm

@hutm hutm commented Sep 17, 2026

Copy link
Copy Markdown

Problem

Every Kubernetes Event write currently blocks checkpoint or restore reconciliation. A slow Event API request can delay the workload even though Normal events are best-effort telemetry.

Why

Informational event delivery should not be part of the restore critical path. Warning events still need synchronous error reporting.

Change

Publish Normal events through a bounded worker queue. Keep Warning events synchronous, copy queued Pod data, and drop a Normal event with a diagnostic when the queue is full.

This removes a blocking dependency from the critical path, but local end-to-end measurements did not show a statistically significant latency improvement.

Testing

  • Verified Normal event publication returns while the API request is blocked.
  • Verified Warning event publication waits for the API request.
  • Ran the complete agent test suite and event publisher race tests.

Fixes #351

Signed-off-by: Maksim Khadkevich <mkhadkevich@nvidia.com>
@copy-pr-bot

copy-pr-bot Bot commented Sep 17, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@coderabbitai

coderabbitai Bot commented Sep 17, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Comment @coderabbitai help to get the list of available commands.

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.

Keep Normal Event writes off the restore critical path

1 participant