John R.webp

How we brought down our build times. General optimization tips

Manuel Nakamurakare

Android Build Engineer


At Pinterest, we focused Q1 2021 working on reducing the p95 time for Android builds. We were able to bring the time down by 30%.

In this talk, I’ll share our learnings from our experience in improving the build times. This was mostly done in a big monolithic app, but several of these tips are also applicable to a modularized app

Key Takeaways:
Make sure your app is using the right gradle settings
Build cache is pretty sensitive.Things like having empty folders, changes in resources, having non deterministic method order can affect them
Use a tool for build debugging such as Gradle Enterprise
Optimize usage of incremental build cache, local cache and remote cache

I'm a curious engineer currently trying think about ways to make cross functional teams work together and be more productive. When not at work, you can find me hitting up the slopes, or hiking with my wife