# In Apigee Hybrid, where exactly are Quota/Rate limiting counters stored — Cassandra or Redis?

**URL:** <https://discuss.google.dev/t/in-apigee-hybrid-where-exactly-are-quota-rate-limiting-counters-stored-cassandra-or-redis/286776>\
**Category:** Apigee\
**Tags:** hybrid, apigee-general\
**Created:** [November 13, 2025, 8:33am UTC](https://discuss.google.dev/t/in-apigee-hybrid-where-exactly-are-quota-rate-limiting-counters-stored-cassandra-or-redis/286776 "2025-11-13T08:33:01Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![nikhild28](https://d3byx8b92xw3lq.cloudfront.net/user_avatar/discuss.google.dev/nikhild28/32/34552_2.png) [@nikhild28](https://discuss.google.dev/u/nikhild28)\
**Post date:** [November 13, 2025, 8:33am UTC](https://discuss.google.dev/t/in-apigee-hybrid-where-exactly-are-quota-rate-limiting-counters-stored-cassandra-or-redis/286776/1 "2025-11-13T08:33:01Z")

</div>

I’ve configured a **Spike Arrest policy** (example: 3 requests per 1 minute) and wanted to understand the **exact flow of how counters are handled and stored** in the hybrid architecture.

Based on my understanding:

- Message Processor (MP) enforces the policy.

- Redis is used for caching/runtime coordination.

- Cassandra is used as the persistent datastore.

Could you please confirm:

1. Whether the **quota counters are persisted in Cassandra** or Redis (or both)?

2. What is the **role of Redis** in rate limiting (is it L1/L2 cache or coordination layer)?

3. How does the **request flow** look when a client hits the API (Client → Router → MP → Redis → Cassandra)?

4. Is there any **official Apigee doc or architecture diagram** explaining this interaction for Hybrid?

@dchiesa1@apigeedebugger#Google Cloud > Apigee#Apigee > Knowledge Hub

---

<div class="post-metadata">

**Author:** ![paul-wright](https://d3byx8b92xw3lq.cloudfront.net/user_avatar/discuss.google.dev/paul-wright/32/119264_2.png) [@paul-wright](https://discuss.google.dev/u/paul-wright)\
**Post date:** [November 13, 2025, 7:26pm UTC](https://discuss.google.dev/t/in-apigee-hybrid-where-exactly-are-quota-rate-limiting-counters-stored-cassandra-or-redis/286776/2 "2025-11-13T19:26:47Z")

</div>

Hi,

In Apigee we have two types of rate limiting policies:

1. Quota: Used for contractual rate limiting over time.

- Think counting calls by consumers in Minutes, Hours, and Days
- Quotas are stored in Cassandra with rate synchronized by on the Quota policies configuration.

1. Spike Arrest: Used for (either or both) non-contractual consumer rate limiting and/or target protection. In either case, Spike is designed to help smooth traffic preventing redlining.

- Think rough counting of calls in seconds or milliseconds
- Spike Arrest counts in memory on the Message Processors
- Spike Arrest will use Redis to coordinate counts when UseEffectiveCount is set

Note: A request’s flow never routes through Redis nor Cassandra. Calls flow: Client → Istio (routing) → MP → Target

This guide shows the connections between components within Hybrid, however it does not show the triggering events that drive each connection: [Secure ports usage &nbsp;|&nbsp; Apigee &nbsp;|&nbsp; Google Cloud](https://cloud.google.com/apigee/docs/hybrid/v1.15/ports#internal)

For more information between these two policies please see:

- [Rate-limiting &nbsp;|&nbsp; Apigee &nbsp;|&nbsp; Google Cloud Documentation](https://docs.cloud.google.com/apigee/docs/api-platform/develop/rate-limiting)
- [Comparing Quota and SpikeArrest policies &nbsp;|&nbsp; Apigee &nbsp;|&nbsp; Google Cloud Documentation](https://docs.cloud.google.com/apigee/docs/api-platform/develop/comparing-quota-and-spike-arrest-policies)

Cheers,
