How Google Manages Trillions of Authorizations with Zanzibar
Zanzibar is Google's global authorization system that handles over 10 million permission checks per second across services like Drive, YouTube, and Maps. It uses a tuple-based data model to represent permissions, employs zookies (tokens) with Google Spanner's TrueTime for consistency guarantees, and runs on 10,000+ servers across 30+ geographic locations. The system achieves 99.999% availability through distributed caching, request deduplication, and client isolation, with 99% of checks served in 3ms median latency. Key architectural decisions include flexible relation tuples, causality-respecting consistency protocols, and optimized serving layers with intelligent caching strategies.