US01-02 — Establish Application and Database Foundation #2

Closed
opened 2026-07-13 13:10:36 +02:00 by domverse · 3 comments
Owner

Source specification: delivery_backlog/stories/US01-02-app-database-foundation.md

US01-02 — Establish Application and Database Foundation

Epic: E01

As an operator, I want the API, worker configuration, and database lifecycle to start
consistently so later services share one durable foundation.

Acceptance criteria

  • FastAPI factory, typed configuration, SQLAlchemy sessions, Alembic, WAL, foreign
    keys, structured logging, and readiness are configured.
  • Stable asset IDs, path occurrences, versions, and audit timestamps have migrations.
  • Secrets are referenced through configuration and never returned or logged.
  • Startup and shutdown leave no leaked worker or database resources.

Automated tests

  • Migrations pass from an empty database and supported legacy schema snapshots.
  • Process-level integration tests verify readiness, restart, WAL, foreign keys, and
    clean shutdown.

Dependencies

  • US01-01
Source specification: [delivery_backlog/stories/US01-02-app-database-foundation.md](https://git.domverse-berlin.eu/domverse/photoanalyzer/src/branch/main/delivery_backlog/stories/US01-02-app-database-foundation.md) # US01-02 — Establish Application and Database Foundation Epic: [E01](https://git.domverse-berlin.eu/domverse/photoanalyzer/src/branch/main/delivery_backlog/E01-shared-identity-inventory.md) As an operator, I want the API, worker configuration, and database lifecycle to start consistently so later services share one durable foundation. ## Acceptance criteria - FastAPI factory, typed configuration, SQLAlchemy sessions, Alembic, WAL, foreign keys, structured logging, and readiness are configured. - Stable asset IDs, path occurrences, versions, and audit timestamps have migrations. - Secrets are referenced through configuration and never returned or logged. - Startup and shutdown leave no leaked worker or database resources. ## Automated tests - Migrations pass from an empty database and supported legacy schema snapshots. - Process-level integration tests verify readiness, restart, WAL, foreign keys, and clean shutdown. ## Dependencies - US01-01
domverse added this to the E01 — Shared Identity and Inventory milestone 2026-07-13 13:10:36 +02:00
domverse added the type/featurearea/databasearea/backendpriority/normal labels 2026-07-13 13:10:36 +02:00
domverse added a new dependency 2026-07-13 13:11:14 +02:00
domverse added a new dependency 2026-07-13 13:11:14 +02:00
domverse added a new dependency 2026-07-13 13:11:15 +02:00
domverse added this to the Photo Analyzer Delivery project 2026-07-13 13:19:43 +02:00
domverse added the status/backlog label 2026-07-13 13:52:43 +02:00
domverse added status/in-progress and removed status/backlog labels 2026-07-15 16:16:30 +02:00
domverse self-assigned this 2026-07-15 16:16:30 +02:00
Author
Owner

Claimed for implementation on branch us/US01-02-establish-application-and-database-foundation.

Claimed for implementation on branch `us/US01-02-establish-application-and-database-foundation`.
domverse added status/review and removed status/in-progress labels 2026-07-15 16:30:31 +02:00
Author
Owner

Submitted for review: #47

Tests passed:

  • work_item/scripts/python -m unittest discover -s work_item/tests -v
  • work_item/scripts/python -m pytest tests -q
  • work_item/scripts/python -m pytest tests/unit tests/integration -q
Submitted for review: https://git.domverse-berlin.eu/domverse/photoanalyzer/pulls/47 Tests passed: - `work_item/scripts/python -m unittest discover -s work_item/tests -v` - `work_item/scripts/python -m pytest tests -q` - `work_item/scripts/python -m pytest tests/unit tests/integration -q`
domverse added status/done and removed status/review labels 2026-07-15 16:33:28 +02:00
Author
Owner

Completed and merged via PR #47.

Completed and merged via PR #47.
domverse moved this to Done in Photo Analyzer Delivery on 2026-08-16 11:58:01 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Reference: domverse/photoanalyzer#2