Edge KV is a globally distributed key-value store that runs at points of presence (POPs). Writes propagate to all POPs automatically, and Edge Routine (ER) reads data from the same POP where the request lands, keeping latency low. Common use cases include lightweight Blockchain as a Service (BaaS) and API gateway services.
How it works
Edge KV is eventually consistent: writes land at the central POP first, then propagate to edge POPs.
The full write-then-read sequence:
A write is submitted through the ESA console or API. The data is stored in the central POP's KV storage.
ESA invalidates any stale copies of that key at the edge POPs to prevent serving outdated values.
On the next read, ER retrieves the key-value pair from the nearest edge POP.
Hot read: the key is cached at the edge POP. The read is served immediately.
Cold read: the key is not yet cached. ESA fetches the value from the central POP and caches it at the edge POP. Subsequent reads become hot reads.
The first read after a write may hit the central POP, so newly written data has higher latency on first access. Once cached, subsequent reads are fast regardless of where requests originate.
When to use Edge KV
Edge KV is well suited for read-heavy, globally consistent workloads:
Serving configuration values or feature flags at the edge
Storing user preferences or session tokens for global access
Implementing allowlists or denylists for API gateways
Caching computed results that update infrequently
Deploying lightweight BaaS logic that reads shared state
Edge KV is not a good fit for write-heavy workloads. If your application updates the same key many times per second—such as a real-time counter or live leaderboard—the eventual consistency model and propagation delay will cause stale reads. Use a database with strong consistency guarantees instead.
Key concepts
-
Namespace
A namespace is an isolated container for key-value pairs, identified by a globally unique name within your account. Namespaces keep data logically separated, preventing key collisions across different applications or environments. Create a namespace before adding any key-value pairs to it.
-
KV (key-value pair)
A key-value pair is the fundamental unit of storage in Edge KV. Each pair belongs to exactly one namespace. Specify the target namespace when reading or writing a key-value pair.