Skip to main content

Getting Started

Requirements​

  • You need Java JRE installed (Java 17 or later).

  • To use the plugin you need Gradle version 9.2.1 or later.

Using the plugin​

To start you need to create a directory for the project, then you should add a build.gradle file with following content into your build.gradle file.

Gradle Plugin Portal Version

plugins {
id 'co.com.bancolombia.cleanArchitecture' version '5.0.5'
}

Then you can list the tasks available with the command:

gradle tasks

You can follow one of the next steps to create a quick start project with commands

Quick Start​

mkdir scaffold-quick-start
cd scaffold-quick-start
echo "plugins {
id 'co.com.bancolombia.cleanArchitecture' version '5.0.5'
}" > build.gradle
gradle wrapper
./gradlew ca --name=ScaffoldQuickStart
./gradlew gep --type webflux
./gradlew bootRun

Then open your browser and go to http://localhost:8080/api/usecase/path and it will reply with an empty string, to change the response you can modify the Handler class in the entry-points/reactive-web

Build and coverage reports​

Run the complete build and the merged JaCoCo report with:

./gradlew build jacocoMergedReport

Gradle builds the task graph for both requested tasks and executes shared tasks only once. The command runs the standard build lifecycle (assemble and check), including compilation, validateStructure, and the subproject tests. The merged report adds these quality tasks:

TaskWhat it does
jacocoTestReport in each moduleCollects JaCoCo coverage after that module's tests.
jacocoMergedReport at the rootMerges module execution data into root XML and HTML reports.
pitest in each moduleRuns mutation analysis when Pitest is declared in the root plugins {} block.
pitestReportAggregate at the rootCombines module PIT results into root HTML and XML reports when Pitest is declared.

When Pitest is not declared, the build, module tests, and merged JaCoCo report still run; PIT tasks are omitted. See JaCoCo Merged Report for report locations and task details.

Tasks

The Scaffolding Clean Architecture plugin will allow you the next tasks: