Skip to content

Commit

Permalink
enh(samples): using BOM instead of importing individual SpringBoot de…
Browse files Browse the repository at this point in the history
…pendencies
  • Loading branch information
lprimak committed Dec 19, 2023
1 parent c1fcedd commit ba01d28
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 49 deletions.
45 changes: 0 additions & 45 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -998,24 +998,6 @@
<version>${project.version}</version>
</dependency>

<!-- Shiro samples: -->
<dependency>
<groupId>org.apache.shiro.samples</groupId>
<artifactId>samples-spring-client</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-starter</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-web-starter</artifactId>
<version>${project.version}</version>
</dependency>


<!-- Intra project test dependencies: -->
<dependency>
<groupId>org.apache.shiro</groupId>
Expand Down Expand Up @@ -1403,33 +1385,6 @@
</exclusions>
</dependency>

<!-- Spring Boot-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
<version>${spring-boot.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-autoconfigure</artifactId>
<version>${spring-boot.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-configuration-processor</artifactId>
<version>${spring-boot.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-test</artifactId>
<version>${spring-boot.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<version>${spring-boot.version}</version>
</dependency>

<!-- Guice -->
<dependency>
<groupId>com.google.inject</groupId>
Expand Down
13 changes: 13 additions & 0 deletions samples/spring-boot-web/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-web-starter</artifactId>
<version>${project.version}</version>
</dependency>

<dependency>
Expand Down Expand Up @@ -73,6 +74,18 @@
</dependency>
</dependencies>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>${spring-boot.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<build>
<plugins>
<plugin>
Expand Down
15 changes: 13 additions & 2 deletions samples/spring-boot/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@
</properties>

<dependencies>

<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-starter</artifactId>
<version>${project.version}</version>
</dependency>

<!-- Spring -->
Expand Down Expand Up @@ -67,9 +67,20 @@
<artifactId>log4j-core</artifactId>
<scope>runtime</scope>
</dependency>

</dependencies>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>${spring-boot.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<build>
<plugins>
<plugin>
Expand Down
4 changes: 2 additions & 2 deletions samples/web-jakarta/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<dependency>
<groupId>org.glassfish.web</groupId>
<artifactId>jakarta.servlet.jsp.jstl</artifactId>
<version>2.0.0</version>
<version>3.0.1</version>
<scope>compile</scope>
</dependency>

Expand All @@ -92,7 +92,7 @@
<dependency>
<groupId>jakarta.servlet.jsp.jstl</groupId>
<artifactId>jakarta.servlet.jsp.jstl-api</artifactId>
<version>2.0.0</version>
<version>3.0.0</version>
<scope>test</scope>
<exclusions>
<exclusion>
Expand Down
7 changes: 7 additions & 0 deletions support/spring-boot/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>${spring-boot.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<!--
The spring test API uses mockito, as much as I prefer mockito over easymock, one mock framework is
probably enough, so putting in this pom makes that more obvious.
Expand Down
1 change: 1 addition & 0 deletions support/spring-boot/spring-boot-web-starter/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-starter</artifactId>
<version>${project.version}</version>
</dependency>

<!-- Spring -->
Expand Down
2 changes: 2 additions & 0 deletions test-coverage/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,12 @@
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-starter</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-spring-boot-web-starter</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>

Expand Down

0 comments on commit ba01d28

Please sign in to comment.