Task 03 completes the code-host store conversions.
Risks
Sentry uses guarded table rebuilds for multi-instance settings. PostgreSQL replay must not enter SQLite rebuild paths.
Parallelism
sequential
Inputs
Jira, Linear, and Sentry store tests.
apps/backend/internal/integrations/AGENTS.md
Results
Adapted Jira, Linear, and Sentry schema DDL and additive migrations to the
active driver, including PostgreSQL timestamp and boolean forms.
Reused shared schema probes and rebound store and transaction queries across
configuration, health, watches, resets, and reservations.
Replaced SQLite-only INSERT OR IGNORE reservation statements with
portable ON CONFLICT ... DO NOTHING clauses.
Kept the Jira/Linear singleton migrations and Sentry instance/watch rebuilds
on SQLite, so PostgreSQL startup does not enter SQLite catalog or PRAGMA
paths.
Preserved integer-backed health flags with explicit CASE conversion and
retained Sentry duplicate/FK error mapping on PostgreSQL.
Added PostgreSQL fresh/replay coverage for settings, health, watches,
instance binding, FK protection, and reservation operations in all three
packages.
Verification: KANDEV_TEST_POSTGRES_DSN=<local test DSN> go test -race ./internal/jira ./internal/linear ./internal/sentry -run 'TestPostgresStore' -v passed.
Verification: KANDEV_TEST_POSTGRES_DSN=<local test DSN> go test -race ./internal/jira ./internal/linear ./internal/sentry passed.