Skip to content

feat: refactor certificate repository for DynamoDB single-table - #9

Open
maxsonferovante wants to merge 4 commits into
masterfrom
feature/single-table-dynamodb
Open

feat: refactor certificate repository for DynamoDB single-table#9
maxsonferovante wants to merge 4 commits into
masterfrom
feature/single-table-dynamodb

Conversation

@maxsonferovante

Copy link
Copy Markdown
Contributor

Summary

Refactors CertificateRepository for DynamoDB single-table design pattern.

Changes

  • dynamodb_keys.py: Add PK/SK/GSI key generation helpers
  • CertificateRepository: Updated for single-table pattern with GSIs:
    • GSI1: Certificate by UUID
    • GSI2: Certificates by email
    • GSI3: Certificates by product
    • GSI4: Successful certificates
  • EntityType filter: Added to GSI queries
  • config.py: Returns single table name

Related

Part of the single-table migration. Infrastructure PR: PythonFloripa/py-certify-infra

- Add dynamodb_keys.py with PK/SK/GSI key generation helpers
- Refactor CertificateRepository for single-table pattern:
  - Uses GSI1 (UUID), GSI2 (email), GSI3 (product), GSI4 (success)
- Add EntityType filter to GSI queries
- Update config to return single table name
@bentoluizv

Copy link
Copy Markdown
Contributor

dynamodb_keys.py:72 traz o gsi4pk_city, que foi removido no #8. Varri o repo e ele não tem nenhum chamador — esse serviço só mexe com Certificate. Melhor não trazer junto.

This notification service only works with certificates, no need for city access pattern.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants