Dropbox Ryan Harter Mar 29, 2022

Introducing Focus: A New Open Source Gradle Plugin

M2 Related OWASP risk: Inadequate Supply Chain Security Learn more →

Article Summary

Ryan Harter from Dropbox just open-sourced a Gradle plugin that cuts Android Studio sync time by 87%. If you're tired of waiting on builds in large Android projects, this is for you.

Dropbox's monorepo contains nearly 600 Gradle projects, but engineers typically only work in a handful at a time. The new Focus plugin intelligently loads only the modules you need, dramatically improving IDE and build performance. It's now available on GitHub for the entire Android community.

Key Takeaways

Critical Insight

Focus lets Android teams with large modular projects work faster by configuring only the modules they actually need, cutting sync times by up to 87%.

The article reveals the surprisingly simple manual workarounds Dropbox engineers used before building Focus, and why those approaches became unmanageable at scale.

About This Article

Problem

Dropbox's monorepo contained nearly 600 projects. Android Studio had to load modules that most engineers didn't use every day, which created unnecessary configuration overhead and slowed down development as tools took longer to respond.

Solution

Ryan Harter built the Focus Gradle plugin, a settings plugin that looks at project dependencies and automatically generates a minimal settings.gradle file with only the modules needed for a specific feature module.

Impact

Design systems engineers cut their IDE sync time from 1 minute down to 15 seconds. Other teams saw sync times drop from 2 minutes to 20 seconds. These improvements add up across the daily development workflow.