Data logs: The latest evolution in Meta’s access tools
Meta serves per-user data logs from its Hive data warehouse, which cannot handle per-user point queries, by batching many Download Your Information requests into one full-table scan. A scheduled job collects recent requests into a batch run on the Core Workflow Service. It writes the requester IDs to a Hive table, then runs per-table and per-partition Dataswarm jobs that INNER JOIN against each table's owner column. PySpark splits the results into per-user files, and a Hack post-processing step applies privacy filters and renders readable HTML. Lessons include checkpointing for resilience against out-of-memory and timeout failures, a user-ID verification step added after a Spark partitioning bug nearly returned data to the wrong user, and an experimentation platform for testing workflow changes.
Related posts
- Policy Zones: How Meta enforces purpose limitation at scale in batch processing systems
Meta Engineering mediumAdeptMeta's Policy Zones, part of its Privacy Aware Infrastructure, applies information flow control to enforce purpose limitation across an exabyte-scale data warehouse. Datasets and loggers carry Governable Data Annotations such as MESSAGING_DATA, and downstream data must be at least as restrictive as its sources. A SQL parser (UPM) turns queries from processors like Presto into semantic trees. A Policy Evaluation Service checks each flow and issues a cryptographically signed token that the Warehouse Permission Service validates at access time. Policy Zone Manager tooling handles label creep through reclassification, letting the system run across millions of datasets, tens of millions of daily flows and trillions of consent checks per hour.
- Tulip: Modernizing Meta’s data platform
Meta Engineering mediumAdeptMeta migrated its exabyte-scale analytics logging platform from legacy Hive Text Delimited and JSON serialization to the Tulip format across more than 30,000 logging schemas, sharply cutting bytes logged per second while schema counts stayed flat. The migration relied on a mixed-mode wire format, where Tulip payloads are prefixed with the invalid UTF-8 bytes 0x80 0x00 so old and new formats can coexist on one Scribe stream. Supporting tools included format-agnostic Reader libraries and legacy-format converters in consumers, shadow loggers verified by a Spark job comparing rows by ID, a loggertail CLI for decoding streams, and rate-limited rollouts. Scaling to the long tail depended on daily automated targeting of schemas whose consumers were all ready, plus a live migration guide, support group and office hours.
- Migrating Data Ingestion Systems at Meta Scale
Meta Engineering mediumAdeptMeta migrated tens of thousands of MySQL-to-warehouse change data capture (CDC) ingestion jobs, together moving several petabytes daily, from customer-owned pipelines to a self-managed warehouse service, and fully retired the legacy system. Each job went through shadow, reverse-shadow and cleanup phases, with promotion gated on matching row counts and checksums plus no regression in landing latency or resource use. Because CDC carries bad data forward into new partitions, bad partitions were flagged in metadata to halt delta landing or fall back to older target partitions, and backfills gave early rollback signals. Automated promotion/demotion tooling, batch selection that excluded jobs with known issues, and reuse of legacy snapshots cut expensive full dumps under limited capacity.
- How ClickHouse Cloud enabled LaunchDarkly to build and ship features faster
ClickHouse mediumAdept
LaunchDarkly replaced Kinesis/Flink/Lambda streaming pipelines and an S3/Parquet/Athena batch warehouse with ClickHouse Cloud. Raw events are now queried directly, and materialized views are added only where needed. The system ingests about 6 PB/month of uncompressed JSON through an HTTP API, S3 protobuf batches, Lambda-converted Parquet and INSERT INTO SELECT. Data is fresh in about 30 seconds with roughly 100 days of retention, high-cardinality per-user analytics became practical, and seven product features now run on it. Lessons learned: don't coarsen ORDER BY keys, drop OLTP habits (for example, use two-stage queries for latest-N), and plan for workload isolation as adoption outpaces the platform team. Next steps are ingest-time joins for Release Guardian regression detection and migrating Elasticsearch workloads.
- Schematizing Deletion at Scale
Shopify Engineering mediumAdeptShopify handles PII deletion in a warehouse ingesting tens of billions of events per day by requiring privacy-annotated schemas for every analytical event (4,500+ active schemas) and pseudonymising PII before it lands. A Scrubber on the Kafka pipeline applies irreversible obfuscation, such as masking IPs with geo enrichment or reducing user agents to device and OS families. For data that must stay recoverable, it applies tokenization: a vault issues consistent per-controller, per-subject tokens, so a deletion request only removes the token-to-PII mapping in the vault and never touches the petabyte-scale warehouse. Adoption came from making schematized events the default easy path, proving correctness through reconciliation and stress tests, and adding value like dataset discoverability.