Spring Cloud Starter Parent POM providing dependency management and configuration for Spring Cloud applications
npx @tessl/cli install tessl/maven-org-springframework-cloud--spring-cloud-starter-parent@2024.0.0Spring Cloud Starter Parent is a Maven parent POM that provides dependency management and build configuration for Spring Cloud applications. It extends Spring Boot's starter parent and provides centralized dependency management for the Spring Cloud ecosystem through the spring-cloud-dependencies BOM.
pom.xmlTo use Spring Cloud Starter Parent as your project's parent POM:
<parent>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-parent</artifactId>
<version>2024.0.1</version>
<relativePath/>
</parent>This provides:
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-parent</artifactId>
<version>2024.0.1</version>
<relativePath/>
</parent>
<groupId>com.example</groupId>
<artifactId>my-spring-cloud-app</artifactId>
<version>1.0.0</version>
<name>My Spring Cloud Application</name>
<dependencies>
<!-- Spring Cloud dependencies inherit managed versions -->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-gateway</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-config</artifactId>
</dependency>
</dependencies>
</project>Spring Cloud Starter Parent is built around Maven's inheritance mechanism and provides:
org.springframework.boot:spring-boot-starter-parent:3.4.3spring-cloud-dependencies BOM for version managementProvides the foundation POM configuration that child projects inherit.
<parent>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-parent</artifactId>
<version>2024.0.1</version>
<relativePath/>
</parent>Inherited Configuration:
Manages versions for all Spring Cloud dependencies through BOM import.
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>2024.0.1</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>Managed Spring Cloud Modules:
Configurable build properties for child projects.
<properties>
<main.basedir>${basedir}/../..</main.basedir>
<spring-cloud.version>2024.0.1</spring-cloud.version>
</properties>Available Properties:
main.basedir: Base directory reference for multi-module buildsspring-cloud.version: Spring Cloud version for dependency managementSpring repositories profile providing access to Spring artifact repositories.
<profile>
<id>spring</id>
<repositories>
<repository>
<id>spring-snapshots</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/libs-snapshot-local</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>spring-milestones</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/libs-milestone-local</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>spring-releases</id>
<name>Spring Releases</name>
<url>https://repo.spring.io/release</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>spring-snapshots</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/libs-snapshot-local</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>spring-milestones</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/libs-milestone-local</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>Usage:
mvn clean install -PspringArtifact publishing configuration for Spring repositories.
<distributionManagement>
<downloadUrl>https://github.com/spring-cloud</downloadUrl>
<site>
<id>spring-docs</id>
<url>scp://static.springframework.org/var/www/domains/springframework.org/static/htdocs/spring-cloud/docs/${project.artifactId}/${project.version}</url>
</site>
<repository>
<id>repo.spring.io</id>
<name>Spring Release Repository</name>
<url>https://repo.spring.io/libs-release-local</url>
</repository>
<snapshotRepository>
<id>repo.spring.io</id>
<name>Spring Snapshot Repository</name>
<url>https://repo.spring.io/libs-snapshot-local</url>
</snapshotRepository>
</distributionManagement>Additional build profiles for different publishing environments.
Milestone Profile:
<profile>
<id>milestone</id>
<distributionManagement>
<repository>
<id>repo.spring.io</id>
<name>Spring Milestone Repository</name>
<url>https://repo.spring.io/libs-milestone-local</url>
</repository>
</distributionManagement>
</profile>Bintray Profile:
<profile>
<id>bintray</id>
<distributionManagement>
<repository>
<id>bintray</id>
<name>Jcenter Repository</name>
<url>https://api.bintray.com/maven/spring/jars/org.springframework.cloud:${bintray.package}</url>
</repository>
</distributionManagement>
</profile>Central Profile (Maven Central):
<profile>
<id>central</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<distributionManagement>
<snapshotRepository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots/</url>
</snapshotRepository>
<repository>
<id>sonatype-nexus-staging</id>
<name>Nexus Release Repository</name>
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
</profile>Usage Examples:
# Use milestone profile for milestone releases
mvn deploy -Pmilestone
# Use central profile for Maven Central releases
mvn deploy -Pcentral
# Use bintray profile for Bintray/JCenter publishing
mvn deploy -Pbintray
# Use spring profile for Spring repository access
mvn install -Pspring<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-parent</artifactId>
<version>2024.0.1</version>
<name>spring-cloud-starter-parent</name>
<description>Spring Cloud Starter Parent</description>
<packaging>pom</packaging>
<url>https://projects.spring.io/spring-cloud</url>
<organization>
<name>Pivotal Software, Inc.</name>
<url>https://www.spring.io</url>
</organization>