Skip to content

Commit

Permalink
Use Gradle Version Catalog
Browse files Browse the repository at this point in the history
Closes gh-2490
  • Loading branch information
marcusdacoregio committed Oct 18, 2023
1 parent 9ca247a commit 047839e
Show file tree
Hide file tree
Showing 29 changed files with 190 additions and 45 deletions.
45 changes: 0 additions & 45 deletions gradle/dependency-management.gradle

This file was deleted.

116 changes: 116 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
[versions]
ch-qos-logback = "1.4.7"
com-fasterxml-jackson = "2.14.2"
io-projectreactor = "3.5.11"
jakarta-websocket = "2.1.0"
org-apache-derby = "10.16.1.1"
org-codehaus-groovy = "3.0.17"
org-gretty = "4.1.0"
org-mockito = "4.8.1"
org-mongodb = "4.8.2"
org-slf4j = "2.0.7"
org-springframework-boot = "3.0.7"
org-springframework = "6.0.13"
org-testcontainers = "1.17.3"
org-junit = "5.9.3"

[libraries]
ch-qos-logback-logback-classic = { module = "ch.qos.logback:logback-classic", version.ref = "ch-qos-logback" }
ch-qos-logback-logback-core = { module = "ch.qos.logback:logback-core", version.ref = "ch-qos-logback" }
com-fasterxml-jackson-jackson-bom = { module = "com.fasterxml.jackson:jackson-bom", version.ref = "com-fasterxml-jackson" }
com-fasterxml-jackson-core-jackson-databind = { module = "com.fasterxml.jackson.core:jackson-databind", version.ref = "com-fasterxml-jackson" }
com-google-code-findbugs-jsr305 = "com.google.code.findbugs:jsr305:3.0.2"
com-h2database-h2 = "com.h2database:h2:2.1.214"
com-hazelcast = "com.hazelcast:hazelcast:5.1.4"
com-ibm-db2-jcc = "com.ibm.db2:jcc:11.5.7.0"
com-maxmind-geoip2 = "com.maxmind.geoip2:geoip2:2.16.1"
com-microsoft-sqlserver-mssql-jdbc = "com.microsoft.sqlserver:mssql-jdbc:11.2.1.jre17"
com-oracle-database-jdbc-ojdbc8 = "com.oracle.database.jdbc:ojdbc8:21.7.0.0"
com-zaxxer-HikariCP = "com.zaxxer:HikariCP:5.0.1"
edu-umd-cs-mtc-multithreadedtc = "edu.umd.cs.mtc:multithreadedtc:1.01"
io-lettuce-lettuce-core = "io.lettuce:lettuce-core:6.2.1.RELEASE"
io-projectreactor-reactor-bom = { module = "io.projectreactor:reactor-bom", version = "2022.0.12" }
io-spring-javaformat-spring-javaformat-checkstyle = "io.spring.javaformat:spring-javaformat-checkstyle:0.0.29"
io-spring-nohttp-nohttp-checkstyle = "io.spring.nohttp:nohttp-checkstyle:0.0.3.RELEASE"
jakarta-servlet-jakarta-servlet-api = "jakarta.servlet:jakarta.servlet-api:6.0.0"
jakarta-servlet-jsp-jstl-jakarta-servlet-jsp-jstl-api = "jakarta.servlet.jsp.jstl:jakarta.servlet.jsp.jstl-api:3.0.0"
jakarta-websocket-jakarta-websocket-api = { module = "jakarta.websocket:jakarta.websocket-api", version.ref = "jakarta-websocket" }
jakarta-websocket-jakarta-websocket-client-api = { module = "jakarta.websocket:jakarta.websocket-client-api", version.ref = "jakarta-websocket" }
mysql-mysql-connector-java = "mysql:mysql-connector-java:8.0.30"
nz-net-ultraq-thymeleaf-thymeleaf-layout-dialect = "nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect:3.1.0"
org-apache-derby-derby = { module = "org.apache.derby:derby", version.ref = "org-apache-derby" }
org-apache-derby-derbytools = { module = "org.apache.derby:derbytools", version.ref = "org-apache-derby" }
org-apache-httpcomponents-httpclient = "org.apache.httpcomponents:httpclient:4.5.14"
org-apache-logging-log4j-log4j-core = "org.apache.logging.log4j:log4j-core:2.17.1"
org-aspectj-aspectjweaver = "org.aspectj:aspectjweaver:1.9.9.1"
org-assertj-assertj-core = "org.assertj:assertj-core:3.23.1"
org-codehaus-groovy-groovy-cli-commons = { module = "org.codehaus.groovy:groovy-cli-commons", version.ref = "org-codehaus-groovy" }
org-codehaus-groovy-groovy-json = { module = "org.codehaus.groovy:groovy-json", version.ref = "org-codehaus-groovy" }
org-glassfish-web-jakarta-servlet-jsp-jstl = "org.glassfish.web:jakarta.servlet.jsp.jstl:3.0.1"
org-gretty-gretty-runner-jetty11 = { module = "org.gretty:gretty-runner-jetty11", version.ref = "org-gretty" }
org-gretty-gretty-runner-tomcat10 = { module = "org.gretty:gretty-runner-tomcat10", version.ref = "org-gretty" }
org-gretty-gretty-starter = { module = "org.gretty:gretty-starter", version.ref = "org-gretty" }
org-hamcrest = "org.hamcrest:hamcrest:2.2"
org-hsqldb = "org.hsqldb:hsqldb:2.7.0"
org-junit-junit-bom = { module = "org.junit:junit-bom", version.ref = "org-junit" }
org-junit-jupiter-junit-jupiter-api = { module = "org.junit.jupiter:junit-jupiter-api", version.ref = "org-junit" }
org-junit-jupiter-junit-jupiter-engine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "org-junit" }
org-junit-jupiter-junit-jupiter-params = { module = "org.junit.jupiter:junit-jupiter-params", version.ref = "org-junit" }
org-mariadb-jdbc-mariadb-java-client = "org.mariadb.jdbc:mariadb-java-client:3.0.7"
org-mockito-mockito-bom = { module = "org.mockito:mockito-bom", version.ref = "org-mockito" }
org-mockito-mockito-core = { module = "org.mockito:mockito-core", version.ref = "org-mockito" }
org-mockito-mockito-inline = { module = "org.mockito:mockito-inline", version.ref = "org-mockito" }
org-mockito-mockito-junit-jupiter = { module = "org.mockito:mockito-junit-jupiter", version.ref = "org-mockito" }
org-mongodb-mongodb-driver-core = { module = "org.mongodb:mongodb-driver-core", version.ref = "org-mongodb" }
org-mongodb-mongodb-driver-reactivestreams = { module = "org.mongodb:mongodb-driver-reactivestreams", version.ref = "org-mongodb" }
org-mongodb-mongodb-driver-sync = { module = "org.mongodb:mongodb-driver-sync", version.ref = "org-mongodb" }
org-postgresql = "org.postgresql:postgresql:42.5.0"
org-seleniumhq-selenium-htmlunit-driver = "org.seleniumhq.selenium:htmlunit-driver:4.5.2"
org-seleniumhq-selenium-selenium-support = "org.seleniumhq.selenium:selenium-support:4.5.3"
org-skyscreamer-jsonassert = "org.skyscreamer:jsonassert:1.5.1"
org-slf4j-jcl-over-slf4j = { module = "org.slf4j:jcl-over-slf4j", version.ref = "org-slf4j" }
org-slf4j-log4j-over-slf4j = { module = "org.slf4j:log4j-over-slf4j", version.ref = "org-slf4j" }
org-slf4j-slf4j-api = { module = "org.slf4j:slf4j-api", version.ref = "org-slf4j" }
org-springframework-boot-spring-boot-devtools = { module = "org.springframework.boot:spring-boot-devtools", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-gradle-plugin = { module = "org.springframework.boot:spring-boot-gradle-plugin", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-actuator = { module = "org.springframework.boot:spring-boot-starter-actuator", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-data-jpa = { module = "org.springframework.boot:spring-boot-starter-data-jpa", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-data-mongodb = { module = "org.springframework.boot:spring-boot-starter-data-mongodb", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-data-mongodb-reactive = { module = "org.springframework.boot:spring-boot-starter-data-mongodb-reactive", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-data-redis = { module = "org.springframework.boot:spring-boot-starter-data-redis", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-security = { module = "org.springframework.boot:spring-boot-starter-security", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-test = { module = "org.springframework.boot:spring-boot-starter-test", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-thymeleaf = { module = "org.springframework.boot:spring-boot-starter-thymeleaf", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-validation = { module = "org.springframework.boot:spring-boot-starter-validation", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-web = { module = "org.springframework.boot:spring-boot-starter-web", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-webflux = { module = "org.springframework.boot:spring-boot-starter-webflux", version.ref = "org-springframework-boot" }
org-springframework-boot-spring-boot-starter-websocket = { module = "org.springframework.boot:spring-boot-starter-websocket", version.ref = "org-springframework-boot" }
org-springframework-data-spring-data-bom = "org.springframework.data:spring-data-bom:2022.0.11"
org-springframework-security-spring-security-bom = "org.springframework.security:spring-security-bom:6.0.8"
org-springframework-spring-framework-bom = { module = "org.springframework:spring-framework-bom", version.ref = "org-springframework"}
org-springframework-spring-context = { module = "org.springframework:spring-context", version.ref = "org-springframework"}
org-springframework-spring-jcl = { module = "org.springframework:spring-jcl", version.ref = "org-springframework"}
org-springframework-spring-jdbc = { module = "org.springframework:spring-jdbc", version.ref = "org-springframework"}
org-springframework-spring-messaging = { module = "org.springframework:spring-messaging", version.ref = "org-springframework"}
org-springframework-spring-test = { module = "org.springframework:spring-test", version.ref = "org-springframework"}
org-springframework-spring-web = { module = "org.springframework:spring-web", version.ref = "org-springframework"}
org-springframework-spring-webflux = { module = "org.springframework:spring-webflux", version.ref = "org-springframework"}
org-springframework-spring-webmvc = { module = "org.springframework:spring-webmvc", version.ref = "org-springframework"}
org-springframework-spring-websocket = { module = "org.springframework:spring-websocket", version.ref = "org-springframework"}
org-springframework-springloaded = "org.springframework:springloaded:1.2.8.RELEASE"
org-testcontainers-testcontainers-bom = { module = "org.testcontainers:testcontainers-bom", version.ref = "org-testcontainers" }
org-thymeleaf-extras-thymeleaf-extras-springsecurity6 = "org.thymeleaf.extras:thymeleaf-extras-springsecurity6:3.1.1.RELEASE"
org-webjars-bootstrap = "org.webjars:bootstrap:2.3.2"
org-webjars-html5shiv = "org.webjars:html5shiv:3.7.3-1"
org-webjars-knockout = "org.webjars:knockout:3.5.1"
org-webjars-sockjs-client = "org.webjars:sockjs-client:1.5.1"
org-webjars-stomp-websocket = "org.webjars:stomp-websocket:2.3.4"
org-webjars-webjars-locator-core = "org.webjars:webjars-locator-core:0.52"

[plugins]
io-spring-antora-generate-antora-yml = "io.spring.antora.generate-antora-yml:0.0.1"
nl-littlerobots-version-catalog-update = "nl.littlerobots.version-catalog-update:0.8.1"
org-antora = "org.antora:1.0.0"
org-gretty = "org.gretty:4.1.0"
org-springframework-boot = "org.springframework.boot:3.0.7"
org-springframework-boot-aot = "org.springframework.boot.aot:3.0.7"
2 changes: 2 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ plugins {

rootProject.name = 'spring-session-build'

include 'spring-session-dependencies'
include 'spring-session-bom'
include 'spring-session-core'
include 'spring-session-data-mongodb'
Expand All @@ -28,3 +29,4 @@ file('spring-session-samples').eachDirMatch(~/spring-session-sample-.*/) { dir -
rootProject.children.each { project ->
project.buildFileName = "${project.name}.gradle"
}

2 changes: 2 additions & 0 deletions spring-session-core/spring-session-core.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ apply plugin: 'io.spring.convention.spring-module'
description = "Spring Session"

dependencies {
management platform(project(":spring-session-dependencies"))

api "org.springframework:spring-jcl"

optional "io.projectreactor:reactor-core"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ apply plugin: 'io.spring.convention.spring-module'
description = "Spring Session and Spring MongoDB integration"

dependencies {
management platform(project(":spring-session-dependencies"))

api project(':spring-session-core')

Expand Down
1 change: 1 addition & 0 deletions spring-session-data-redis/spring-session-data-redis.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ apply plugin: 'io.spring.convention.spring-module'
description = "Spring Session Redis implementation"

dependencies {
management platform(project(":spring-session-dependencies"))
api project(':spring-session-core')
api ("org.springframework.data:spring-data-redis") {
exclude group: "org.slf4j", module: 'jcl-over-slf4j'
Expand Down
46 changes: 46 additions & 0 deletions spring-session-dependencies/spring-session-dependencies.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
plugins {
id 'java-platform'
}

javaPlatform {
allowDependencies()
}

dependencies {
api platform(libs.io.projectreactor.reactor.bom)
api platform(libs.com.fasterxml.jackson.jackson.bom)
api platform(libs.org.junit.junit.bom)
api platform(libs.org.mockito.mockito.bom)
api platform(libs.org.springframework.spring.framework.bom)
api platform(libs.org.springframework.data.spring.data.bom)
api platform(libs.org.springframework.security.spring.security.bom)
api platform(libs.org.testcontainers.testcontainers.bom)
constraints {
api libs.com.hazelcast
api libs.org.aspectj.aspectjweaver
api libs.ch.qos.logback.logback.core
api libs.com.google.code.findbugs.jsr305
api libs.com.h2database.h2
api libs.com.ibm.db2.jcc
api libs.com.microsoft.sqlserver.mssql.jdbc
api libs.com.oracle.database.jdbc.ojdbc8
api libs.com.zaxxer.hikariCP
api libs.edu.umd.cs.mtc.multithreadedtc
api libs.io.lettuce.lettuce.core
api libs.jakarta.servlet.jakarta.servlet.api
api libs.jakarta.websocket.jakarta.websocket.api
api libs.jakarta.websocket.jakarta.websocket.client.api
api libs.mysql.mysql.connector.java
api libs.org.apache.derby.derby
api libs.org.apache.derby.derbytools
api libs.org.assertj.assertj.core
api libs.org.hamcrest
api libs.org.hsqldb
api libs.org.mariadb.jdbc.mariadb.java.client
api libs.org.mongodb.mongodb.driver.core
api libs.org.mongodb.mongodb.driver.sync
api libs.org.mongodb.mongodb.driver.reactivestreams
api libs.org.postgresql
}
}

1 change: 1 addition & 0 deletions spring-session-docs/spring-session-docs.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ apply plugin: 'io.spring.convention.docs'
apply plugin: 'io.spring.convention.spring-test'

dependencies {
management platform(project(":spring-session-dependencies"))
testImplementation project(':spring-session-core')
testImplementation project(':spring-session-data-redis')
testImplementation project(':spring-session-hazelcast')
Expand Down
1 change: 1 addition & 0 deletions spring-session-hazelcast/spring-session-hazelcast.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-module'

dependencies {
management platform(project(":spring-session-dependencies"))
api project(':spring-session-core')
api "com.hazelcast:hazelcast"
api "org.springframework:spring-context"
Expand Down
1 change: 1 addition & 0 deletions spring-session-jdbc/spring-session-jdbc.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ apply plugin: 'io.spring.convention.spring-module'
description = "Spring Session and Spring JDBC integration"

dependencies {
management platform(project(":spring-session-dependencies"))
api project(':spring-session-core')
api "org.springframework:spring-context"
api "org.springframework:spring-jdbc"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-hazelcast')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-actuator"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-jdbc')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-mongodb')
implementation "org.springframework.boot:spring-boot-starter-webflux"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-mongodb')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework.boot:spring-boot-starter-webflux"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework.boot:spring-boot-starter-webflux"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
apply plugin: 'io.spring.convention.spring-sample-boot'

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework.boot:spring-boot-starter-web"
implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ plugins {
}

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-data-redis')
implementation "org.springframework:spring-web"
implementation "io.lettuce:lettuce-core"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ plugins {
}

dependencies {
management platform(project(":spring-session-dependencies"))
implementation project(':spring-session-hazelcast')
implementation "org.springframework:spring-web"
implementation "org.springframework.security:spring-security-config"
Expand Down
Loading

0 comments on commit 047839e

Please sign in to comment.