Skip to content
CAI
Software that uses CAICheck a score

awasisto/android-clean-architecture-samples

56.0

Adequate · 21 September 2026

3.3k

lines of production code

Java

with Kotlin

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a collection of Android application samples demonstrating architectural patterns for a GitHub user finder tool. It provides reference implementations in both Java and Kotlin, specifically showcasing Model-View-Presenter (MVP) and Model-View-ViewModel (MVVM) structures. Each sample includes a complete stack with data, domain, and UI layers, utilizing technologies like SQLite, Retrofit, and AndroidX.

How it got here

2018 — Legacy code removal and AndroidX migration

6 changes.

This period was dominated by the complete removal of legacy Android application modules, including MVP and MVVM implementations, along with associated data and domain layers. Concurrently, the project migrated to AndroidX and updated its build configuration, signaling a shift away from the previous architecture towards a modernized codebase.

2021 — Multi-architecture demo implementations

9 changes.

This period focused on expanding the repository's reference implementations by adding complete MVP and MVVM architecture samples in both Java and Kotlin. The work involved building out the UI, domain, and data layers for these new demos, alongside introducing local search history persistence and logging infrastructure.

Features

Add Kotlin MVP demo

The application now includes a complete MVP (Model-View-Presenter) implementation in Kotlin. This adds a search interface that allows users to search for GitHub users, view search history, and see user details. The implementation includes a data layer with SQLite for search history, a domain layer with use cases, and a UI layer with activities, adapters, and presenters. Tests are also added for the domain use cases.

(repo-wide) · high confidence

Added Java MVP demo for the Android app

The Android UI layer has been implemented using the Model-View-Presenter (MVP) architecture. This includes the Search and User Details activities, their corresponding presenters and view interfaces, and the necessary Android resources (manifest, themes, strings, and layouts). The implementation also includes a service locator for dependency injection and a main thread executor for UI updates. Additionally, unit tests have been added for the SearchPresenter and UserDetailsPresenter to verify the presenter logic.

mvp-java/ui · high confidence

Added Java MVP demo project

A new Java-based Model-View-Presenter (MVP) architecture sample has been added to the repository. This includes the project's README, Gradle wrapper configuration, and standard build/proguard rules for the data, domain, and UI layers, providing a clean reference implementation for this architectural pattern.

mvp-java · high confidence

Added Java MVP demo with domain, data, and common layers

The Java MVP demo application was added, introducing a complete MVP architecture across three modules. The domain layer defines interfaces for GitHub and search history data sources, along with use cases for searching users, retrieving user details, and fetching search history. The data layer implements these interfaces using Retrofit for the GitHub API and SQLite for local search history storage, while the common module provides a logging abstraction. Tests were also added for the domain use cases.

mvp-java/common, mvp-java/data, mvp-java/domain · high confidence

Added Kotlin MVP and MVVM demo implementations

The UI layer now includes two complete demo implementations for the GitHub User Finder app: an MVP (Model-View-Presenter) architecture in the 'mvp-kotlin' module and an MVVM (Model-View-ViewModel) architecture in the 'mvvm-kotlin' module. The MVP implementation introduces domain models for search history and user data, along with a service locator for dependency injection. The MVVM implementation provides ViewModels for the search and user detail screens, utilizing a reusable Event wrapper for UI events. These additions provide users with reference implementations for different architectural patterns in Kotlin.

ui · high confidence

Initial Android UI implementation for the GitHub User Finder app

The \mvvm-java/ui\ module now contains the complete Android application code, including the \AndroidManifest.xml\ defining the \SearchActivity\ and \UserDetailsActivity\ entry points. The UI layer is built with MVVM architecture, featuring \SearchViewModel\ and \UserDetailsViewModel\ that manage state via \LiveData\. The implementation includes a \ServiceLocator\ for dependency injection, \MainThreadExecutorService\ for UI thread management, and \BindingAdapters\ for image loading and view visibility. Layouts for search results, search history, and user details are provided, along with the necessary drawables and themes. Additionally, unit tests have been added for \SearchViewModel\ and \UserDetailsViewModel\ to verify the new behavior.

mvvm-java/ui · high confidence

Introduce MVVM architecture with data binding and use cases

The Android UI layer has been refactored from an MVP structure to an MVVM architecture. This introduces a domain layer with use cases (e.g., \SearchUsersUseCase\, \GetUserUseCase\) and data source interfaces, wired together via a \ServiceLocator\ and \ViewModelFactory\. The UI now utilizes Android Data Binding with custom \BindingAdapters\ for image loading and view visibility, and includes layout resources for search results, history, and user details. Additionally, a \NoOpLogger\ implementation is provided for testing purposes.

mvvm-kotlin/ui · high confidence

Introduced local search history persistence and domain use cases

The application now supports local search history. A new \SearchHistoryDataSource\ interface and \SqliteSearchHistoryDataSource\ implementation were added to the data layer, backed by a \SearchHistoryDbHelper\ that manages a SQLite database. The domain layer introduces \GetSearchHistoryUseCase\ and \SearchUsersUseCase\ (which logs search queries to the history). A \Logger\ interface and \AndroidLogger\ implementation were also added to the common and data layers to support logging. Tests were added for the new use cases.

(repo-wide) · high confidence

Removals

Removal of core application components and data layers

The entire data and domain layers for the GitHub user finder application have been removed. This includes the removal of the AndroidManifest, the main application class, all data source interfaces and implementations (including the GitHub API client, search history database, and their respective Dagger modules), as well as the domain layer use cases and the base UseCase abstract class. This effectively strips the application of its ability to fetch user data or maintain local search history.

mvp-dagger-rxjava/src · high confidence

Removed legacy Android MVP implementation

The \mvp-kotlin\ module's entire codebase, including the \com.wasisto.githubuserfinder\ package, has been removed. This includes all data sources (GitHub API, search history), domain use cases, and UI components (activities, presenters, adapters). The removal eliminates the legacy Android MVP architecture from the project.

mvp-kotlin · high confidence

Removed legacy Android source code

The \mvp/src\ module's entire source tree has been removed, including the \AndroidManifest.xml\, all Java classes (data sources, use cases, UI components, and models), and associated resources. This eliminates the app's previous implementation, which relied on the \com.wasisto.githubuserfinder\ package structure.

mvp/src · high confidence

Removed legacy MVVM architecture components and data layer

Deleted the entire \dev-mvvm-architecturecomponents\ module, including the \com.wasisto.githubuserfinder\ package. This removes the old data source implementations (GitHub and Search History), domain use cases, and UI components (Activities, Adapters, ViewModels) that relied on the \Callback\ interface and manual threading. The removal eliminates the previous callback-based asynchronous handling in favor of a new architecture.

dev-mvvm-architecturecomponents/src · high confidence

Behavioural changes

Removed Gradle wrapper configuration

The Gradle wrapper configuration file (gradle-wrapper.properties) has been removed from the project. This file previously defined the Gradle distribution URL and paths, meaning the project no longer bundles or manages a specific version of the Gradle build tool via the standard wrapper mechanism.

gradle · high confidence

Restructure Java and Kotlin samples with Gradle wrapper and build configuration

The Java and Kotlin MVVM sample projects have been restructured to include Gradle wrapper scripts (gradlew/gradlew.bat) and configuration files (gradle-wrapper.properties) for consistent build environments. Additionally, .gitignore files and ProGuard configuration files (proguard-rules.pro) have been added to the root and subdirectories (common, data, domain, ui) to manage build artifacts and code shrinking rules. The project structure now explicitly separates data, domain, and UI layers with corresponding build and ignore configurations.

mvvm-java, mvvm-kotlin · high confidence

Dependencies

Migrate to AndroidX and update build configuration

The project has been migrated to AndroidX, enabling the use of modern Android libraries and improved support libraries. The Gradle build system has been updated to use Gradle plugin 4.0.2 and Kotlin version 1.5.21. Additionally, the repository has been restructured into modular components for MVP and MVVM patterns in both Java and Kotlin, with updated dependencies including Retrofit 2.9.0, Glide 4.12.0, and Material Design 1.4.0.

(dependencies) · medium confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 52 → 56 (+3.6)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 98 (-1.6)
  • Architecture 100 → 88 (-12.3)
  • Maturity 55 → 55 (+0.0)
  • Readiness 24 → 36 (+11.7)
  • Security 100 → 100 (+0.0)

Resolved (5)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • No exposed public API
  • Test reliability not included
  • single-maintainer — knowledge-concentration (bus factor) risk

New (13)

  • Dependency hygiene PARTLY measured — Maven/Gradle declarations read, no dependency graph resolved
  • Duplicated block (10 lines × 2) (mvvm-java/ui/src/main/java/com/wasisto/githubuserfinder/android/ui/search/SearchActivity.java)
  • Duplicated block (18 lines × 2) (mvp-java/data/src/main/java/com/wasisto/githubuserfinder/android/data/searchhistory/SearchHistoryDbHelper.java)
  • Duplicated block (18 lines × 2) (mvp-java/domain/src/main/java/com/wasisto/githubuserfinder/domain/usecases/SearchUsersUseCase.java)
  • Duplicated block (24 lines × 2) (mvp-java/data/src/main/java/com/wasisto/githubuserfinder/android/data/searchhistory/SqliteSearchHistoryDataSource.java)
  • Duplicated block (33 lines × 2) (mvp-java/domain/src/main/java/com/wasisto/githubuserfinder/domain/models/SearchHistoryItem.java)
  • Duplicated block (46 lines × 2) (mvp-java/ui/src/main/java/com/wasisto/githubuserfinder/android/MainThreadExecutorService.java)
  • Duplicated block (47 lines × 2) (mvp-java/data/src/main/java/com/wasisto/githubuserfinder/android/data/github/RetrofitGithubDataSource.java)
  • Duplicated block (51 lines × 2) (mvp-java/ui/src/main/java/com/wasisto/githubuserfinder/android/DefaultServiceLocator.java)
  • Duplicated block (63 lines × 2) (mvp-java/data/src/main/java/com/wasisto/githubuserfinder/android/data/logger/AndroidLogger.java)
  • Duplicated block (66 lines × 2) (mvp-java/domain/src/main/java/com/wasisto/githubuserfinder/domain/models/SearchUsersResult.java)
  • Duplicated block (77 lines × 2) (mvp-java/domain/src/main/java/com/wasisto/githubuserfinder/domain/models/User.java)
  • Duplicated block (8 lines × 2) (mvp-java/data/src/main/java/com/wasisto/githubuserfinder/android/data/searchhistory/SqliteSearchHistoryDataSource.java)

Architecture

  • Containers 0 added · 0 removed · contexts 1 added · 0 removed · edges 1 added · 0 removed

Added bounded contexts (1)

  • domain

Added dependency edges (1)

  • ui → domain (coupling)

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

awasisto/android-clean-architecture-samples was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 21 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit c76f9df77f1d5ab5421a6663af37014a22979a50 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-fa71c66cabd8.