feat(scheduler): wire startup migrations, dedupe 007/008, fix UI trend path

TASK-013: SchedulerPersistenceExtensions now calls AddStartupMigrations so
the embedded SQL files (including 007 job_kind + 008 doctor_trends) run on
every cold start. Deletes duplicate migrations 007_add_job_kind_plugin_config
(kept 007_add_schedule_job_kind.sql with tenant-scoped index) and
008_doctor_trends_table (kept 008_add_doctor_trends.sql with RLS + BRIN
time-series index).

TASK-010: Doctor UI trend service now calls
/api/v1/scheduler/doctor/trends/categories/{category} (was
/api/v1/doctor/scheduler/...) so it routes through the scheduler plugin
endpoints rather than the deprecated standalone doctor-scheduler path.

TASK-009: New DoctorJobPluginTests exercises plugin lifecycle: identity,
config validation for full/quick/categories/plugins modes, plan creation,
JSON schema shape, and PluginConfig round-trip (including alerts). 10 tests
added, all pass (26/26 in Plugin.Tests project).

Archives the sprint — all 13 tasks now DONE — and archives the platform
retest sprint (SPRINT_20260409_002) whose RETEST-008 completed via the
earlier feed-mirror cleanup.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
master
2026-04-13 22:14:30 +03:00
parent 0b09298a3a
commit 62d865080d
8 changed files with 251 additions and 63 deletions

View File

@@ -108,7 +108,7 @@ export class HttpDoctorClient implements DoctorApi {
const requests = cats.map(category =>
this.http.get<{ category: string; dataPoints: Array<{ timestamp: string; healthScore: number }> }>(
`/api/v1/doctor/scheduler/trends/categories/${category}`,
`/api/v1/scheduler/doctor/trends/categories/${category}`,
{ params: { from, to } }
).pipe(
map(res => ({