Skip to content

jeffjensen/java-service-archetype

Repository files navigation

java-service-archetype

Maven archetype that generates a structured multi-module Java service project. You describe your integrations, service areas, and presentation architectural tiers at generation time; the archetype builds the full module tree and wires up all POMs.

Generate a Project

mvn archetype:generate \
  -DarchetypeGroupId=io.github.jeffjensen \
  -DarchetypeArtifactId=java-service-archetype \
  -DarchetypeVersion=1.0.0

See the project site for the full prompts reference, module structure, examples, and build instructions.

CI / CD

Three GitHub Actions workflows are included.

Build any branch (build-any-branch.yml)

Runs ./mvnw clean verify on every push and pull request. Documentation-only changes (.adoc, .md, src/site/**) are skipped — those pushes trigger the site publish directly instead.

Deploy snapshot (deploy-snapshot.yml)

Triggered when the build workflow succeeds on main. Publishes a -SNAPSHOT artifact to Maven Central (Sonatype). Release versions (without -SNAPSHOT) are skipped automatically.

Required repository secrets:

Secret Description

CENTRAL_USERNAME

Maven Central portal username

CENTRAL_TOKEN

Maven Central portal token

Publish site (publish-docs.yml)

Triggered in three ways: when the build workflow succeeds on main; on any direct push to main that touches doc files (.adoc, .md, src/site/**); or manually via workflow_dispatch. Runs ./mvnw site and publishes the Maven site to GitHub Pages.

Enable GitHub Pages (repository Settings → Pages → Source: GitHub Actions) before the first run.

About

Maven archetype that generates a structured multi-module Java service project with integration, service, and presentation architectural tiers

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors