<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu" -->

---
title: real-time usage metering and plan entitlements for Phoenix
description: Aurora Meter is a new MIT-licensed Elixir library for Phoenix apps that handles usage metering, quota gating, and plan entitlements — the counting-and-billing...
canonical: https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: real-time usage metering and plan entitlements for Phoenix | daily.dev
og:description: Aurora Meter is a new MIT-licensed Elixir library for Phoenix apps that handles usage metering, quota gating, and plan entitlements — the counting-and-billing...
og:url: https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu
og:image: https://api.daily.dev/og/posts/58URfmeEu.png
og:image:alt: real-time usage metering and plan entitlements for Phoenix
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# real-time usage metering and plan entitlements for Phoenix

**[ElixirStatus](https://daily.dev/sources/elixirstatus)** · 3 min read · 0 upvotes · 0 comments

## Summary

Aurora Meter is a new MIT-licensed Elixir library for Phoenix apps that handles usage metering, quota gating, and plan entitlements — the counting-and-billing layer many SaaS builders end up hand-rolling. Counts are tracked via ETS increments with no database hit on the write path, a background flusher periodically persists snapshots to Postgres, and a PubSub broadcaster updates LiveView usage bars in near real time. Plans are defined via a compile-time DSL supporting hard caps, metered overage, and feature flags. Benchmarks show ~7.9M increments/s across distinct counters and ~53k/s on a single contended counter. Known limitations: counters are per-node (no cross-node merging yet), buffered writes can lose up to one flush interval on crash, and periods are fixed to UTC calendar months with Postgres-only support. A paid Pro tier adds Stripe billing integration, webhook sync, and dashboards.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://forum.elixirforum.com/t/aurora-meter-real-time-usage-metering-and-plan-entitlements-for-phoenix/76602>

## Questions this post answers

### Is there a Laravel Cashier equivalent for usage-based billing in Elixir/Phoenix apps?

Not until Aurora Meter, a free MIT-licensed library that handles usage metering and plan entitlements for Phoenix. It tracks counts via ETS increments with no database hit on the write path, gates access against plan limits, and flushes snapshots to Postgres periodically. A paid Pro add-on layers on Stripe checkout, webhook sync, and dashboards for teams that need billing integration.

_daily.dev surfaces new Elixir tooling like this for developers building SaaS billing without reinventing it._

### How fast can ETS counters handle usage tracking in an Elixir application?

A benchmark using eight concurrent processes on a dev laptop with Elixir 1.20 and OTP 29 measured about 7.9 million increments per second when counters were distinct, dropping to roughly 53,000 per second when all eight processes hammered a single shared counter, showing contention as the main bottleneck rather than raw ETS throughput.

_track how libraries like Aurora Meter benchmark concurrency trade-offs via daily.dev._

### What are the current limitations of Aurora Meter for multi-node Phoenix deployments?

Counters are tracked per node with no cross-node merging yet, so a multi-node deployment should either run the meter on a single node or mark critical features as durable, which writes an event row synchronously instead of relying on buffered flushes. Buffered writes can also lose up to one flush interval of increments on a hard crash, and periods are limited to UTC calendar months with Postgres as the only supported backend.

_developers evaluating usage-metering tools for production Phoenix apps can follow these trade-offs on daily.dev._

## Similar posts on daily.dev

- [GitHub - liamkillingback/aurora-meter: Real-time usage metering, plan entitlements, and Stripe-ready billing primitives for Phoenix.](https://daily.dev/posts/github---liamkillingback-aurora-meter-real-time-usage-metering-plan-entitlements-and-stripe-ready-d09rwmofh) · ElixirStatus · 0 upvotes · 0 comments
- [All roads lead to metered pricing](https://daily.dev/posts/all-roads-lead-to-metered-pricing-yvoujksya) · Kilo Blog · 132 upvotes · 31 comments
- [Improved cost transparency with usage-based billing](https://daily.dev/posts/improved-cost-transparency-with-usage-based-billing-uwkc8hggl) · Temporal · 0 upvotes · 0 comments
- [Inside Atlassian’s Forge Billing Architecture for Distributed Usage Tracking at Scale](https://daily.dev/posts/inside-atlassian-s-forge-billing-architecture-for-distributed-usage-tracking-at-scale-isyc0ega4) · InfoQ · 1 upvotes · 0 comments
- [Why I Built an Application-Level Quota Manager for Laravel](https://daily.dev/posts/why-i-built-an-application-level-quota-manager-for-laravel-vkdcfqv00) · Medium · 4 upvotes · 0 comments

---

Tags: [#elixir](https://daily.dev/tags/elixir), [#liveview](https://daily.dev/tags/liveview)

[View this post on daily.dev](https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"real-time usage metering and plan entitlements for Phoenix","url":"https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu"},"datePublished":"2026-09-07T06:43:07.404Z","dateModified":"2026-09-07T12:10:02.764Z","description":"Aurora Meter is a new MIT-licensed Elixir library for Phoenix apps that handles usage metering, quota gating, and plan entitlements — the counting-and-billing...","image":"https://media.daily.dev/image/fetch/s--0b-LOs94--/f_auto,pg_1,q_auto/https://forum.elixirforum.com/uploads/default/original/3X/6/5/65f4c9ea7b49c21aa074c2711b9cb1d1b04943a0.gif?_a=BAMAMiZY0","thumbnailUrl":"https://media.daily.dev/image/fetch/s--0b-LOs94--/f_auto,pg_1,q_auto/https://forum.elixirforum.com/uploads/default/original/3X/6/5/65f4c9ea7b49c21aa074c2711b9cb1d1b04943a0.gif?_a=BAMAMiZY0","isAccessibleForFree":true,"articleSection":"ElixirStatus","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"ElixirStatus","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/22e4640538124187827caf8cc8e39190","url":"https://daily.dev/sources/elixirstatus"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"elixir,liveview","timeRequired":"PT3M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"ElixirStatus","item":"https://daily.dev/sources/elixirstatus"},{"@type":"ListItem","position":3,"name":"real-time usage metering and plan entitlements for Phoenix"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/real-time-usage-metering-and-plan-entitlements-for-phoenix-58urfmeeu#faq","mainEntity":[{"@type":"Question","name":"Is there a Laravel Cashier equivalent for usage-based billing in Elixir/Phoenix apps?","acceptedAnswer":{"@type":"Answer","text":"Not until Aurora Meter, a free MIT-licensed library that handles usage metering and plan entitlements for Phoenix. It tracks counts via ETS increments with no database hit on the write path, gates access against plan limits, and flushes snapshots to Postgres periodically. A paid Pro add-on layers on Stripe checkout, webhook sync, and dashboards for teams that need billing integration. daily.dev surfaces new Elixir tooling like this for developers building SaaS billing without reinventing it."}},{"@type":"Question","name":"How fast can ETS counters handle usage tracking in an Elixir application?","acceptedAnswer":{"@type":"Answer","text":"A benchmark using eight concurrent processes on a dev laptop with Elixir 1.20 and OTP 29 measured about 7.9 million increments per second when counters were distinct, dropping to roughly 53,000 per second when all eight processes hammered a single shared counter, showing contention as the main bottleneck rather than raw ETS throughput. track how libraries like Aurora Meter benchmark concurrency trade-offs via daily.dev."}},{"@type":"Question","name":"What are the current limitations of Aurora Meter for multi-node Phoenix deployments?","acceptedAnswer":{"@type":"Answer","text":"Counters are tracked per node with no cross-node merging yet, so a multi-node deployment should either run the meter on a single node or mark critical features as durable, which writes an event row synchronously instead of relying on buffered flushes. Buffered writes can also lose up to one flush interval of increments on a hard crash, and periods are limited to UTC calendar months with Postgres as the only supported backend. developers evaluating usage-metering tools for production Phoenix apps can follow these trade-offs on daily.dev."}}]}
```

