GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - spring-projects/spring-modulith: Modular applications with Spring Boot

BranchesTags
Open more actions menu

Latest commit

 

History

1,288 Commits
1,288 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
.mvn
.mvn
 
 
etc
etc
 
 
spring-modulith-actuator
spring-modulith-actuator
 
 
spring-modulith-api
spring-modulith-api
 
 
spring-modulith-apt
spring-modulith-apt
 
 
spring-modulith-benchmarks
spring-modulith-benchmarks
 
 
spring-modulith-bom
spring-modulith-bom
 
 
spring-modulith-core
spring-modulith-core
 
 
spring-modulith-distribution
spring-modulith-distribution
 
 
spring-modulith-docs
spring-modulith-docs
 
 
spring-modulith-events
spring-modulith-events
 
 
spring-modulith-examples
spring-modulith-examples
 
 
spring-modulith-integration-test
spring-modulith-integration-test
 
 
spring-modulith-junit
spring-modulith-junit
 
 
spring-modulith-moments
spring-modulith-moments
 
 
spring-modulith-observability
spring-modulith-observability
 
 
spring-modulith-runtime
spring-modulith-runtime
 
 
spring-modulith-starters
spring-modulith-starters
 
 
spring-modulith-test
spring-modulith-test
 
 
src/docs
src/docs
 
 
.git-authors
.git-authors
 
 
.gitignore
.gitignore
 
 
CONTRIBUTING.adoc
CONTRIBUTING.adoc
 
 
LICENSE
LICENSE
 
 
application.yml
application.yml
 
 
lombok.config
lombok.config
 
 
mvnw
mvnw
 
 
mvnw.cmd
mvnw.cmd
 
 
pom.xml
pom.xml
 
 
pom.xml.versionsBackup
pom.xml.versionsBackup
 
 
readme.adoc
readme.adoc
 
 
release-train-settings.xml
release-train-settings.xml
 
 
release.properties
release.properties
 
 
settings.xml
settings.xml
 
 

Repository files navigation

Spring Modulith Revved up by Develocity

Spring Modulith allows developers to build well-structured Spring Boot applications and guides developers in finding and working with application modules driven by the domain. It supports the verification of such modular arrangements, integration testing individual modules, observing the application’s behavior on the module level and creating documentation snippets based on the arrangement created.

Quickstart

  1. Create a Spring Boot application on https://start.spring.io

  2. Add Spring Modulith to your application by adding this to your pom.xml:

    <!-- Include the BOM for simplified version management -->
    <dependencyManagement>
      <dependencies>
        <dependency>
          <groupId>org.springframework.modulith</groupId>
          <artifactId>spring-modulith-bom</artifactId>
          <version>2.0.5</version>
          <scope>import</scope>
          <type>pom</type>
        </dependency>
      </dependencies>
    </dependencyManagement>
    
    <dependencies>
    
      <!-- The test dependency to pull in verification APIs -->
    
      <dependency>
        <groupId>org.springframework.modulith</groupId>
        <artifactId>spring-modulith-starter-test</artifactId>
        <scope>test</scope>
      </dependency>
    
    </dependencies>
  3. Create a Java package arrangement that puts business modules as direct sub-packages of the application’s main package.

    □ Example
    └─ □ src/main/java
       ├─ □ example           <1>
       |  └─ Application.java
       ├─ □ example.inventory <2>
       |  └─ …
       └─ □ example.order     <2>
          └─ …
    1. The application root package

    2. Application module packages

  4. Create an ApplicationModules model, run verifications and create documentation snippets.

    class ApplicationTests {
    
      @Test
      void writeDocumentationSnippets() {
    
        var modules = ApplicationModules.of(Application.class).verify(); (1)
    
        new Documenter(modules) (2)
          .writeModulesAsPlantUml()
          .writeIndividualModulesAsPlantUml();
      }
    }
    1. Creates application module model and verifies its structure.

    2. Renders Asciidoctor snippets (component diagrams, application module canvas) to target/modulith-docs.

  5. Run integration tests for individual application modules.

    □ Example
    └─ □ src/test/java
       └─ □ example.order
          └─ OrderModuleIntegrationTests.java
    @ApplicationModuleTests
    class OrderModuleIntegrationTests {
    
      @Test
      void someTestMethod() { … }
    }

Reference documentation

Find the reference documentation here.

Contributing

Pull requests are welcome. Note, that we expect everyone to follow the code of conduct.

What you will need

  • Git

  • Java 17 or higher

  • Docker version 1.6.0 or higher

Get the Source Code

Clone the repository

git clone [email protected]:spring-projects/spring-modulith.git
cd spring-modulith

Build the code

To compile, test, and build

./mvnw -B

License

Spring Modulith is Open Source software released under the Apache 2.0 license.

About

Modular applications with Spring Boot

spring.io/projects/spring-modulith

Topics

architecturemodularityspring-boot

Resources

Readme
Apache-2.0 license

Code of conduct

Code of conduct

Contributing

Contributing

Security policy

Security policy
Activity
Custom properties

Stars

1.2k stars

Watchers

23 watching

Forks

240 forks
Report repository

Releases

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.