Skip to content

[DO NOT MERGE] Spike interface for managing timeouts - #3166

Draft
SzymonPobiega wants to merge 1 commit into
masterfrom
timeout-management-spike
Draft

SzymonPobiega wants to merge 1 commit into
masterfrom
timeout-management-spike

Conversation

@SzymonPobiega

@SzymonPobiega SzymonPobiega commented Oct 19, 2026 •

Copy link
Copy Markdown
Member

ServicePulse gets a Timeouts area that lists saga timeouts reported to ServiceControl and lets an operator reschedule, trigger, or cancel a pending timeout.

The design is in docs/saga-timeout-management-design.md in Particular/ServiceControl#6025, which also implements the API this page calls. The endpoint side is Particular/NServiceBus#7996. ServicePulse never changes a timeout directly: an action sends a request through ServiceControl to the endpoint, and the page shows the result when the endpoint reports it.

Changes

  • A Timeouts menu item, gated on GET /api/timeouts through apiRoutes.ts. Its badge shows the overdue count when it is above zero.
  • /timeouts with Pending, Overdue, and All tabs, a search and filter bar, and a paged table: due time, timeout, saga and correlation value, last change with its source, and status. It refreshes every 5 seconds.
  • /timeouts/:timeoutId shows the details, the payload, the history, and the other timeouts of the saga instance. A reschedule that keeps the previous due time is labeled "Payload updated".
  • The actions are Reschedule, Trigger now, and Cancel, which asks for confirmation. Each sends the version the page shows, and a 409 shows a warning and reloads the timeout. Ticking "Change payload" opens a payload editor and renames the button to "Edit and reschedule".
  • While a request waits for the endpoint, the actions are disabled and the page refreshes every second. Forget appears for Unknown timeouts and for requests with no response after 10 minutes.
  • Triggered and canceled timeouts are read-only.
  • MSW handlers and a timeouts mock scenario simulate an endpoint that applies requests after 3 seconds, so npm run dev:mocks shows the pages.

Deviations from the design

  • There is no minimum ServiceControl version gate. Against a ServiceControl without this API, the menu item shows and the list is empty.
  • Actions stay locked while any request is pending. The design lets a new request through after 10 minutes.
  • Not implemented: grouping, the change history tab, failed-trigger status, and the saga diagram additions.

Verification

  • 21 new component and application tests pass, including the "Edit and reschedule" label.
  • npm run type-check, ESLint, and vite build pass.
  • The full suite has one failure, test/mocks/platform-health-state.spec.ts, which also fails on master.
  • With Node below 24 the tooling needs NODE_OPTIONS=--experimental-strip-types.
  • Ran against ServiceControl#6025 with RabbitMQ through the .NET host's /api proxy. The API calls the page makes were exercised end to end; the pages were not checked in a browser.

🤖 Generated with Claude Code

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.

2 participants