Skip to content

fix(entitlements): consume endpoint doesn't persist usage events#198

Merged
chitrank2050 merged 7 commits into
mainfrom
fix/146-entitlements-consume-endpoint-doesnt-persist-usage-events
May 27, 2026
Merged

fix(entitlements): consume endpoint doesn't persist usage events#198
chitrank2050 merged 7 commits into
mainfrom
fix/146-entitlements-consume-endpoint-doesnt-persist-usage-events

Conversation

@chitrank2050

@chitrank2050 chitrank2050 commented May 27, 2026

Copy link
Copy Markdown
Owner
  • Write usage_event + outbox_event in transaction after Redis increment
  • Events flow through existing pipeline: outbox → Kafka → aggregation
  • Ensures consumed usage is durable and reaches billing invoices
  • Non-blocking: Redis increment is the fast path, DB write is best-effort
  • Uses consume-endpoint source tag in metadata for traceability

Closes #146

- Write usage_event + outbox_event in transaction after Redis increment
- Events flow through existing pipeline: outbox → Kafka → aggregation
- Ensures consumed usage is durable and reaches billing invoices
- Non-blocking: Redis increment is the fast path, DB write is best-effort
- Uses consume-endpoint source tag in metadata for traceability

Closes #146
@chitrank2050 chitrank2050 self-assigned this May 27, 2026
@chitrank-actions chitrank-actions Bot added the area/logic Application source code changes label May 27, 2026
@chitrank2050 chitrank2050 changed the title fix(entitlements): persist usage events on consume endpoint fix(entitlements): consume endpoint doesn't persist usage events May 27, 2026
@chitrank-actions chitrank-actions Bot added the area/ci CI/CD workflows and actions configuration label May 27, 2026
@chitrank-actions chitrank-actions Bot added the area/docs Documentation files and markdown files label May 27, 2026
@chitrank2050
chitrank2050 merged commit 5e82f52 into main May 27, 2026
9 checks passed
@chitrank2050
chitrank2050 deleted the fix/146-entitlements-consume-endpoint-doesnt-persist-usage-events branch May 27, 2026 11:32
This was referenced May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/ci CI/CD workflows and actions configuration area/docs Documentation files and markdown files area/logic Application source code changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(entitlements): consume endpoint doesn't persist usage events

1 participant