The ERD mandates bigint identity primary keys and UUID public IDs for specific
indexer tables, while indexer_definition must not expose a public ID in v1.
API and service layers depend on stable public identifiers without leaking internal
bigint keys.
Decision:
Verify the following tables use BIGINT GENERATED ALWAYS AS IDENTITY primary keys and
enforce UUID public IDs (unique) where required:
app_user
indexer_instance
routing_policy
policy_set
policy_rule
search_profile
search_request
canonical_torrent
canonical_torrent_source
torznab_instance
rate_limit_policy
secret
Confirm indexer_definition has no public ID in v1.
Consequences:
Indexer APIs can safely use UUIDs/keys without exposing internal bigint IDs.
Table definitions align with ERD identity rules, reducing migration drift.
Follow-up:
Re-verify new tables against this rule before adding API or UI surfaces.