Data Lineage at Slack
Slack built a central Data Lineage Service that automatically captures table- and column-level lineage by hooking Airflow success callbacks and dashboard audit logs, then parsing the submitted SQL with ANTLR (backed by a large unit-test suite). Raw lineage lands in RDS MySQL, and a daily Spark job uses Pregel to traverse the dependency graph and write a flattened Hive table with a 'layer' column, so transitive downstream dependencies come back from a single query. A Data Portal notify feature uses this lineage to message downstream owners in Slack about deprecations and retention changes. Lineage for non-SQL Spark jobs, a graph database and automated schema-change alerts are listed as future work.
Related posts
- How Meta discovers data flows via lineage at scale
Meta Engineering mediumAdeptMeta builds a data lineage graph across its web, data warehouse and AI systems to find where sensitive data such as Facebook Dating religion fields flows, so privacy controls like Policy Zones can be applied. Signals come from static code analysis, from Privacy Probes runtime instrumentation, and from SQL analysis of Presto and Spark query logs and AI training configs. Privacy Probes captures sampled source and sink payloads within a request and classifies pairs as a high-confidence match-set (exact or contains match) or a noisier full-set that can include transformed flows. An iterative tool in Policy Zone Manager then walks the graph from sources, with developers or heuristics excluding irrelevant nodes so that whole downstream branches are pruned at once.
- How Grab built Scarlet: the AI teammate that turns a Slack message into a production data pipeline
Grab Engineering mediumAdeptGrab's ADW team rebuilt Scarlet, its Slack-based data-pipeline agent, around a short core prompt plus a versioned library of Markdown skills (platform, routing, repository, workflow) loaded on demand, shrinking the prompt about 25x and letting new teams onboard by adding one reviewed repository skill. Platform tools sit behind two-tool MCP bridges, data-platform actions run under the requester's short-lived token, and sign-in pauses use LangGraph interrupts to resume runs. Scarlet now validates the data its changes produce by comparing CI candidate output against production (schema, counts, keys, nulls, stats, row diffs), with inconclusive treated as failure and verdicts bound to commits. Deterministic scaffolds replaced model guesses for predictable config, and after rollout the merge rate rose from about 50% to over 85% while repositories served grew about fourfold.
- Scaling Privacy Infrastructure for GenAI Product Innovation
Meta Engineering easyNoviceMeta scales its Privacy Aware Infrastructure (PAI) to cover GenAI products such as its AI glasses, using cross-stack data lineage as the foundation for automated privacy enforcement. Lineage signals are collected from web privacy probes, logger-to-warehouse flows, parsed SQL and batch-processing logs, RPC boundaries for LLM inference calls, and training manifests, then stitched into an end-to-end graph. A shared library, PrivacyLib, links reads to writes through a common correlation key across languages and data systems. The resulting lineage guides where Policy Zones are placed and blocks training jobs on data not permitted for that purpose, while verifiers continuously watch flow edges to catch new or changed processing early.
- Unlocking Efficiency and Performance: Navigating the Spark 3 and EMR 6 Upgrade Journey at Slack
Slack Engineering mediumAdeptSlack migrated 60+ EMR clusters serving 40+ teams from EMR 5 (Spark 2.4/Hive 2) to EMR 6 with Spark 3 as the single compute engine. Old and new clusters ran side by side during the year-long move. A shared Hive Metastore upgraded from 2.3 to 3.1 via Hive Schema Tool, parallel Bazel builds for Spark 2 and 3 JARs, and an Airflow operator flag to route jobs between cluster versions made that possible. Code changes covered replacing RAND()-based skew salting with AQE, setting storeAssignmentPolicy to Legacy, and disabling convertMetastoreParquet to avoid schema-merge StackOverflowErrors. Exact-match validation with Trino except/count queries preceded the switch, and most pipelines then ran 30–60% faster (some 90%), helped by AQE skew-join handling, shuffle partition coalescing and the EMRFS S3-optimized committer.
- From SSH to REST: A Security-Driven Modernization of Slack’s EMR Data Pipelines
Slack Engineering mediumAdeptSlack replaced 700+ SSH-based Airflow operators that ran jobs directly on EMR master nodes with REST-based submission through Quarry, its internal job gateway. The migration covered 8 data regions over 3 quarters with zero downtime. The key enabler was YARN Distributed Shell, which runs arbitrary shell commands (aws s3 sync, distcp, Python scripts) in managed YARN containers via the standard ResourceManager REST API, while Spark and Hive moved to Livy and HiveServer2. Moving to real YARN submission exposed problems SSH had hidden: vmem check failures, fixed by disabling yarn.nodemanager.vmem-check-enabled, and network-segment dependencies on key-management endpoints. Multi-region rollout multiplied the testing and coordination effort.