BlaBlaCar Patrick Brochado Nov 18, 2021

Reducing Android Build Time at Scale

Article Summary

Patrick Brochado from BlaBlaCar turned a 13-minute Android build into a 4-minute one. His team was losing 8 hours of productivity every single day to slow builds.

BlaBlaCar's Android team tackled their painful build times using Gradle optimization and build analysis tools. Rather than waiting for a complete modularization rewrite, they focused on quick wins that could deliver immediate results with measured effort.

Key Takeaways

Critical Insight

Five targeted optimizations reduced build time by 70% (from 13 to 4 minutes), saving the 12-person team 8 hours of productivity daily.

The article reveals which free Gradle tools provide the best build insights and why your antivirus might be your biggest build performance enemy.

About This Article

Problem

BlaBlaCar's Android team found that the Gradle daemon wasn't being reused consistently between Android Studio and terminal builds. This caused unnecessary recompilation and wasted cache benefits.

Solution

Patrick Brochado's team made sure JAVA_HOME was correctly set in terminal environments and matched the JDK location in Android Studio settings. This allowed the same Gradle daemon to be shared across both build contexts.

Impact

The daemon optimization reduced build time by 1 minute 30 seconds. File system watching and configuration cache features were also enabled, which improved incremental build performance through better memory-based caching.