Traveloka Sep 9, 2019

Dagger and Multi-Module Architecture in Traveloka Android App

Article Summary

Alifa Nurani Putri and Yusuf Cahyo Nugroho from Traveloka reveal how their single Dagger component ballooned to 17,705 lines of code across 25+ products. Their refactoring journey cut initialization time and build times while preparing for Dynamic Feature Modules.

Traveloka's Android team started with a simple Dagger setup in 2016, but as they scaled to 25+ products, their AppComponent became a god object with 82 modules and 36 subcomponents. This deep dive walks through their multi-year refactoring journey to fix build times, memory issues, and enable modularization.

Key Takeaways

Critical Insight

By splitting their monolithic Dagger component into product-specific api, base, and internal modules, Traveloka reduced initialization time by 39% and significantly improved incremental build times.

The article reveals why their attempt at Dynamic Feature Modules initially failed, and what they're planning to try next after completing the refactor.

Recent from Traveloka

Related Articles