Cloudflare K2 Builds Event Streams on R2 Object Storage, at a Second of Produce Latency
Cloudflare has launched K2 in public beta, a serverless event streaming service implementing a durable log on R2 object storage. Cloudflare states produce latency of about one second at p99; a tester reported end-to-end p99 of 7.5 seconds, which a commenter answering for the team said was higher than expected. Consume charges match produce charges per GB. By Steef-Jan Wiggers
Cloudflare has launched K2, a serverless event streaming service, into public beta. K2 relies on Amazon S3 object storage for its partitioned durable log, sacrificing latency for cost and elasticity. Underlying K2 is a trade-off between latency and cost, with a produce latency of about one second at p99. In public testing, end-to-end delivery latency runs slower than one second, with p95 at 2.5 seconds and p99 at 7.5 seconds.
K2's latency comes from a pause during which writes are held in memory on an edge service before being written as a segment file to R2. This pause allows for more efficient storage scaling and compute separation. K2's tech lead agrees that most data systems not requiring sub-100ms latency are moving to object storage. Pricing for K2 is $0.04 per GB produced and $0.02 per GB stored per month, with identical charges for consumption.
This results in an actual usage cost of $0.08 per GB, which is cheaper than self-hosted or cloud-hosted Kafka solutions but can become expensive for fan-out consumer strategies.
Rewritten by urgent.news; may contain errors — check the original.
Source: infoq.com