Migrating Airbnb’s JVM Monorepo to Bazel
Read Full ArticleSummary
The article outlines Airbnb's extensive migration of its JVM monorepo from Gradle to Bazel, detailing the motivations behind the switch, such as improved build speed, reliability, and a unified build infrastructure. It discusses the challenges faced during the migration, including the need for automated build file generation and handling multiple versions of third-party libraries. The authors highlight the significant improvements in build times and developer productivity achieved through the migration process, emphasizing the importance of collaboration with pilot teams and the lessons learned throughout the transition.
Key Learnings
- 1Bazel's remote execution capabilities significantly enhance build performance compared to Gradle, especially for large codebases.
- 2Maintaining co-existing build systems during migration can lead to increased complexity, necessitating automated solutions for build file generation.
- 3Identifying and partnering with pilot teams early in the migration process can provide valuable insights and advocacy for the new system.
- 4Granularity in build configurations can improve performance but may complicate the migration process and increase maintenance overhead.
- 5Ensuring compatibility between Gradle and Bazel-built artifacts is crucial for a smooth transition and minimizing runtime issues.
Who Should Read This
Senior Build Engineers with experience in large-scale build systems looking to optimize CI/CD workflows.
Test Your Knowledge
What are the key advantages of Bazel over Gradle in the context of large monorepo builds?
How did Airbnb address the challenges of maintaining co-existing Gradle and Bazel build systems during migration?
What strategies were employed to ensure that the Bazel build outputs matched those of the Gradle builds?
In what ways did the migration process impact developer productivity, and how was this measured?
What lessons were learned regarding build granularity and its effect on the migration timeline?
Topics
More articles about Bazel
Explore Bazel engineering →More from Airbnb Engineering
View Airbnb engineering blogs →It Wasn’t a Culture Problem: Upleveling Alert Development at Airbnb
The article outlines Airbnb's transformation of its Observability as Code (OaC) alert review process, which significantly reduced development cycles from weeks to minutes. By implementing a system...
Academic Publications & Airbnb Tech: 2025 Year in Review
The article discusses Airbnb's significant advancements in AI and machine learning throughout 2025, particularly in the context of academic conferences such as KDD, CIKM, and EMNLP. It highlights the...
Safeguarding Dynamic Configuration Changes at Scale
The article outlines Airbnb's dynamic configuration platform, Sitar, which enables safe and reliable runtime behavior changes without service interruptions. It emphasizes the importance of a coherent...
My Journey to Airbnb — Anna Sulkina
Anna Sulkina's journey to Airbnb highlights her extensive experience in engineering, particularly in application and cloud infrastructure. She transitioned from hardware diagnostics to software...
Pay As a Local
The article outlines Airbnb's initiative to implement over 20 locally relevant payment methods across various global markets within a year. It details the architectural changes made to their payment...