trails/packages/db/src
Ullrich Schäfer 5ff7af8a81
Add background bulk import for Komoot
Replace the per-tour import UI with a fire-and-forget background job:

- Add `import_batches` DB table tracking status, found/imported/duplicate counts
- Add `runKomootBulkImport` server function that pages all Komoot tours,
  fetches GPX, creates activities, and deduplicates via sync_imports
- Add `komoot-bulk-import` pg-boss job registered at server startup
- Add POST /api/sync/komoot/import to enqueue the job
- Add GET /api/sync/komoot/import-status to return the latest batch
- Replace the Komoot import page with a progress UI that polls every 2s
  while a batch is running and shows found/imported/skipped counts

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-23 18:19:10 +02:00
..
schema Add background bulk import for Komoot 2026-05-23 18:19:10 +02:00
index.test.ts Add tests to all packages, remove passWithNoTests 2026-04-13 00:48:27 +02:00
index.ts Fix planner production server + use .ts extensions everywhere 2026-03-25 01:41:33 +01:00
migrate-data.ts Apply wahoo-route-update: PUT on re-push instead of duplicate POST 2026-05-01 12:08:16 +02:00