feat: make proposal responses durable

This commit is contained in:
Josh Creek
2026-09-01 07:52:52 +01:00
parent 30b4560bd5
commit eef7cf28da
6 changed files with 228 additions and 16 deletions
+4
View File
@@ -37,6 +37,10 @@ func (p postgresProposalBackend) Get(ctx context.Context, playerID, proposalID s
return store.GetProposal(ctx, p.db, playerID, proposalID, now)
}
func (p postgresProposalBackend) Respond(ctx context.Context, playerID, proposalID, idempotencyKey string, accept bool, expectedRevision uint64, now time.Time) (domain.Proposal, error) {
return store.RespondToProposal(ctx, p.db, playerID, proposalID, idempotencyKey, accept, expectedRevision, now)
}
func ProposalProviderFromStore(db *sql.DB) ProposalBackend {
return postgresProposalBackend{db: db}
}