From 031179231cb4c8fcb1087753ae42dd6a320541e0 Mon Sep 17 00:00:00 2001 From: Patrick Johnson Date: Thu, 12 Oct 2023 16:33:20 -0700 Subject: [PATCH] SDGF-151: add versions to javadoc header (#31) * SDGF-151: add versions to javadoc header * SDGF-151: address feedback --- .../gradle/plugins/DependencyConstraints.groovy | 2 -- gradle.properties | 1 + spring-session-data-gemfire/build.gradle | 16 ++++++++++++---- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/build-tools/dependency-constraints/src/main/groovy/com/vmware/gemfire/gradle/plugins/DependencyConstraints.groovy b/build-tools/dependency-constraints/src/main/groovy/com/vmware/gemfire/gradle/plugins/DependencyConstraints.groovy index 51239dd..35cd3b0 100644 --- a/build-tools/dependency-constraints/src/main/groovy/com/vmware/gemfire/gradle/plugins/DependencyConstraints.groovy +++ b/build-tools/dependency-constraints/src/main/groovy/com/vmware/gemfire/gradle/plugins/DependencyConstraints.groovy @@ -38,7 +38,6 @@ class DependencyConstraints { depVersionMapping.put("springVersion","5.3.30") depVersionMapping.put("springBootVersion","2.7.16") depVersionMapping.put("springDataCommonsVersion","2.7.16") - depVersionMapping.put("springSessionVersion","2.7.3") depVersionMapping.put("multithreadedtcVersion","1.01") depVersionMapping.put("apacheLogging","2.14.1") depVersionMapping.put("jsr305Version","3.0.2") @@ -73,7 +72,6 @@ class DependencyConstraints { api(group: 'org.springframework.security', name: 'spring-security-test', version: get('springSecurityVersion')) api(group: 'org.springframework.security', name: 'spring-security-web', version: get('springSecurityVersion')) api(group: 'org.springframework.security', name: 'spring-security-core', version: get('springSecurityVersion')) - api(group: 'org.springframework.session', name: 'spring-session-core', version: get('springSessionVersion')) api(group: 'org.springframework.shell', name: 'spring-shell', version: get('springShellVersion')) api(group: 'org.webjars', name: 'bootstrap', version: '2.3.2') api(group: 'org.webjars', name: 'jquery', version: '1.12.4') diff --git a/gradle.properties b/gradle.properties index 04c8b5c..a57d303 100644 --- a/gradle.properties +++ b/gradle.properties @@ -7,6 +7,7 @@ springDataGemFireVersion=1.1.2 version=1.1.1-build.9999 gemfireVersion=9.15.8 springDataBaseVersion=SD27 +springSessionVersion=2.7.3 additionalMavenRepoURLs='' mavenPushRepository= diff --git a/spring-session-data-gemfire/build.gradle b/spring-session-data-gemfire/build.gradle index dfa27fe..83eb83b 100644 --- a/spring-session-data-gemfire/build.gradle +++ b/spring-session-data-gemfire/build.gradle @@ -19,7 +19,7 @@ java { } javadoc { - title = "Spring Session for VMware GemFire Java API Reference" + title = "Spring Session ${getSpringSessionBaseVersion()} for VMware GemFire ${getGemFireBaseVersion()} Java API Reference" failOnError=false } @@ -34,7 +34,7 @@ dependencies { implementation 'org.springframework:spring-jcl' api "com.vmware.gemfire:spring-data-2.7-gemfire-${getGemFireBaseVersion()}:${springDataGemFireVersion}" - api 'org.springframework.session:spring-session-core:2.7.1' + api "org.springframework.session:spring-session-core:$springSessionVersion" implementation 'com.google.code.findbugs:jsr305' @@ -118,9 +118,17 @@ repositories { } String getGemFireBaseVersion() { - def split = "${gemfireVersion}".split("\\.") + return getBaseVersion(gemfireVersion) +} + +String getSpringSessionBaseVersion() { + return getBaseVersion(springSessionVersion) +} + +static String getBaseVersion(String version) { + def split = "${version}".split("\\.") if (split.length < 2) { - throw new RuntimeException("gemfireVersion is malformed") + throw new RuntimeException("version '$version' is malformed") } return "${split[0]}.${split[1]}" }