multica/server/pkg/db/queries
Jiayuan b112d1f1ae feat(tasks): add coalescing queue and task lifecycle guards
- Coalescing queue: use HasPendingTaskForIssue (queued/dispatched only)
  instead of HasActiveTaskForIssue so comments during a running task
  enqueue exactly one follow-up task that picks up all new comments.
- Stale task cleanup: runtime sweeper now fails orphaned tasks when
  their runtime goes offline (daemon crash/network partition).
- Cancel-aware daemon: handleTask checks task status after execution
  and discards results if the task was cancelled mid-run (e.g. reassign).
- Terminal issue guard: ClaimTaskForRuntime auto-cancels pending tasks
  for done/cancelled issues instead of executing them.
- Race condition safety net: unique partial index ensures at most one
  pending task per issue at the DB level.
2026-03-29 17:52:35 +08:00
..
activity.sql fix(activity): address code review feedback and improve timeline UX 2026-03-29 00:21:46 +08:00
agent.sql feat(tasks): add coalescing queue and task lifecycle guards 2026-03-29 17:52:35 +08:00
comment.sql feat(activity): unified activity timeline with comment reply support 2026-03-28 21:53:08 +08:00
inbox.sql feat(inbox): add priority/due_date notifications, structured details, and hover card 2026-03-29 00:22:17 +08:00
issue.sql refactor: remove acceptance_criteria and context_refs from issues 2026-03-26 19:24:34 +08:00
member.sql feat(server): implement full REST API with JWT auth and real-time WebSocket 2026-03-22 11:50:03 +08:00
personal_access_token.sql feat(auth): email verification login and personal access tokens 2026-03-26 14:32:30 +08:00
runtime.sql feat(tasks): add coalescing queue and task lifecycle guards 2026-03-29 17:52:35 +08:00
runtime_usage.sql feat(runtimes): add usage charts, activity heatmap, and hourly distribution 2026-03-29 15:44:10 +08:00
skill.sql feat: structured skills system with meta skill runtime injection 2026-03-25 15:17:59 +08:00
subscriber.sql feat(notifications): replace hardcoded inbox notifications with subscriber-driven model 2026-03-28 19:33:20 +08:00
user.sql feat(server): implement full REST API with JWT auth and real-time WebSocket 2026-03-22 11:50:03 +08:00
verification_code.sql feat(auth): email verification login and personal access tokens 2026-03-26 14:32:30 +08:00
workspace.sql feat(workspace): add repos JSONB field for GitHub repository URLs 2026-03-27 15:49:30 +08:00