Skip to content

Partition AuditLog by month (native Postgres partitioning) #262

Description

@kilodesodiq-arch

Problem Statement. AuditLog will grow unbounded. Postgres native partition-by-range
keeps old months detached for archival.

Technical Context. Postgres 11+ supports declarative partitioning.

Expected Outcome. Schema rewrite uses a partitioned table with one partition per
month. A Prisma view presents the table for safety.

Acceptance Criteria.

  • Test asserts that AUDIT rows from prior months still query, with the same Prisma
    client API.

Files or modules likely to be affected.
prisma/schema.prisma,
prisma/migrations/*,
docs/db/audit-partitioning.md.

Difficulty. Medium
Estimated effort. M



Backlog item #54 from `docs/maintainer-issue-backlog.md.

Metadata

Metadata

Assignees

Labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions