Skip to content

feat(suite): add suite endpoints and internal service - #250

Merged
BobAnkh merged 4 commits into
devfrom
suite-features
Oct 28, 2026
Merged

BobAnkh merged 4 commits into
devfrom
suite-features

Conversation

@un-lock-able

Copy link
Copy Markdown

Stacked on #247.

Filter tasks and artifacts by suite

  • suite_uuid on task query/cancel and artifact download/delete by-filter requests, with a --suite CLI flag.
  • The suite names its group: it fills in a missing group_name and must match a given one. A suite the caller can't see, one that doesn't exist, and one that contradicts group_name all return the same 404.
  • Task info now includes suite_uuid.

Change suite properties

  • PUT /suites/{uuid} and suites change: name, description, tags, labels, priority, worker schedule, and per-hook changes (set / clear / leave alone). The hooks are merged in SQL inside a single UPDATE.
  • Cancelled suites can't be changed.
  • Worker schedule (1–256 workers) and hook specs are now validated on both create and change.
  • suites create gains --provision/--cleanup/--background.
  • Suite queries are ordered by priority, then creation time.

Suite counters and lock order on cancel and close

  • Fix: task_suite_id was never set on submit, nor kept in the batch-cancel archive, so suite tasks weren't linked to their suite.
  • incomplete_tasks goes down on every cancel path and when a worker archives a task. A Closed suite completes when it reaches zero.
  • The suite counter bump on submit is one statement, guarded by state <> Cancelled, which replaces the read-modify-write.
  • Close is a conditional UPDATE. Cancel marks the suite cancelled before archiving its tasks (so a racing submit can't land in it), archives through a CTE, and includes Cancelled rows.
  • Lock order is suite before task on every path. Batch cancels lock their suites in the same statement as the delete (see the note at the top of service/mod.rs).
  • Task-spawned children may target any suite their parent's group owns, or none. The submit path now pins the group, so report_task no longer checks group_name itself.
  • Triggering a pending suite task no longer pushes it into the worker queues.

@un-lock-able
un-lock-able added this pull request to stack #251 October 16, 2026 09:37
@un-lock-able
un-lock-able requested a review from BobAnkh October 16, 2026 09:37
Base automatically changed from fix-submit-ambiguous-id to dev October 20, 2026 07:49
@un-lock-able

Copy link
Copy Markdown
Author

@BobAnkh This branch is ready to be merged into dev, and after the merge we can work on extracting executor to its separate module and prepare for updating the coordinator to allow executor to report suite tasks and hooks.

@BobAnkh BobAnkh left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Please reformat all the documents; do not break them into such short sentences on each line, it is hard to read actually. It is not the old days. Please break the line at somewhere it should as much as possible, still do not make each line too long or too short. It is better for each line to carry part of the logic and you dont have to search for something next line to understand what this line means. Also please read all your documents. Some of them are really not what we will write in documents. If you want to explain something, you should explain clearly and human-readable. Do not use it as annotation.

I didn't comment on all documents I think is not good, so please check all of them again.

I will review again later for the service/suite and service/task (after you update documents). Others are really good.

Comment thread netmito/src/client/mod.rs Resolved
Comment thread netmito/src/service/suite.rs Resolved
Comment thread netmito/src/service/suite.rs Resolved
@BobAnkh BobAnkh changed the title filter tasks by suite, allow changing suites, fix cancel/close accounting feat(suite): add suite endpoints and internal service Oct 28, 2026
@BobAnkh
BobAnkh merged commit bfde5a5 into dev Oct 28, 2026
11 checks passed
@BobAnkh
BobAnkh deleted the suite-features branch October 28, 2026 13:05
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