Skip to content

Commit 28f2ca6

Browse files
committed
Update to Gradle 7.3.3
Issue gh-610 Closes gh-613 Closes gh-581
1 parent 02ee328 commit 28f2ca6

File tree

221 files changed

+10078
-2323
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

221 files changed

+10078
-2323
lines changed

build.gradle

Lines changed: 0 additions & 207 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ buildscript {
1212
}
1313
dependencies {
1414
classpath "com.github.ben-manes:gradle-versions-plugin:0.17.0"
15-
classpath("org.springframework.build.gradle:propdeps-plugin:0.0.7")
1615
classpath('org.asciidoctor:asciidoctor-gradle-plugin:1.5.1')
1716
classpath("io.spring.gradle:spring-io-plugin:0.0.6.RELEASE")
1817
classpath "org.jfrog.buildinfo:build-info-extractor-gradle:4.12.0"
@@ -21,210 +20,4 @@ buildscript {
2120
}
2221
}
2322

24-
apply plugin: 'org.asciidoctor.gradle.asciidoctor'
25-
26-
ext.GRADLE_SCRIPT_DIR = "${rootProject.projectDir}/gradle"
27-
apply from: "${GRADLE_SCRIPT_DIR}/finalize-deploy.gradle"
28-
ext.JAVA_MODULE_SCRIPT = "${GRADLE_SCRIPT_DIR}/java-module.gradle"
29-
ext.MAVEN_DEPLOYMENT_SCRIPT = "${GRADLE_SCRIPT_DIR}/maven-deployment.gradle"
30-
ext.JAVA_SCRIPT = "${GRADLE_SCRIPT_DIR}/java.gradle"
31-
ext.RELEASE_CHECKS_SCRIPT = "${GRADLE_SCRIPT_DIR}/release-checks.gradle"
32-
ext.SPRING_SNAPSHOT_TEST_SCRIPT = "${GRADLE_SCRIPT_DIR}/spring-snapshot-test.gradle"
33-
34-
ext.coreModules = subprojects.findAll { p-> (!p.name.equals('spring-build-src') && !p.name.contains("test") && !p.name.contains("sample") && !p.name.contains("sandbox")) || p.name.contains("spring-ldap-test") }
35-
36-
allprojects {
37-
apply plugin: 'idea'
38-
apply plugin: 'eclipse'
39-
apply plugin: 'java'
40-
apply plugin: "com.github.ben-manes.versions"
41-
42-
group = "org.springframework.ldap"
43-
44-
ext.releaseBuild = version.endsWith('RELEASE')
45-
ext.snapshotBuild = version.endsWith('SNAPSHOT')
46-
47-
ext.javadocLinks = [
48-
"https://docs.oracle.com/javase/7/docs/api/",
49-
"https://docs.spring.io/spring/docs/3.2.x/javadoc-api/",
50-
"https://logging.apache.org/log4j/1.2/apidocs/",
51-
"https://commons.apache.org/proper/commons-logging/apidocs/",
52-
"https://commons.apache.org/proper/commons-dbcp/apidocs/",
53-
"https://commons.apache.org/proper/commons-pool/apidocs/",
54-
"http://junit.sourceforge.net/javadoc/",
55-
] as String[]
56-
}
57-
58-
59-
configure(subprojects) {
60-
apply plugin: 'propdeps'
61-
apply plugin: 'propdeps-maven'
62-
apply plugin: 'propdeps-idea'
63-
apply plugin: 'propdeps-eclipse'
64-
apply plugin: 'groovy'
65-
apply plugin: "merge"
66-
}
67-
68-
configure(coreModules) {
69-
apply from: JAVA_MODULE_SCRIPT
70-
}
71-
72-
configure(subprojects - coreModules) {
73-
tasks.findByPath("artifactoryPublish")?.enabled = false
74-
tasks.findByPath("uploadArchives")?.enabled = false
75-
}
76-
7723
description = "Spring LDAP"
78-
79-
configurations.archives.artifacts.clear()
80-
apply from: "${GRADLE_SCRIPT_DIR}/deploy-docs.gradle"
81-
apply from: "${GRADLE_SCRIPT_DIR}/deploy-schema.gradle"
82-
83-
asciidoctor {
84-
outputDir = new File("$buildDir/docs")
85-
options = [
86-
eruby: 'erubis',
87-
attributes: [
88-
copycss : '',
89-
icons : 'font',
90-
'source-highlighter': 'prettify',
91-
sectanchors : '',
92-
toc2: '',
93-
idprefix: '',
94-
idseparator: '-',
95-
doctype: 'book',
96-
numbered: '',
97-
'spring-ldap-version' : project.version,
98-
revnumber : project.version
99-
]
100-
]
101-
}
102-
103-
task api(type: Javadoc) {
104-
group = "Documentation"
105-
description = "Generates aggregated Javadoc API documentation."
106-
title = "${rootProject.description} ${version} API"
107-
108-
options.memberLevel = org.gradle.external.javadoc.JavadocMemberLevel.PROTECTED
109-
options.author = true
110-
options.header = rootProject.description
111-
options.splitIndex = true
112-
options.links(project.ext.javadocLinks)
113-
114-
maxMemory = "1536m"
115-
destinationDir = new File(buildDir, "api")
116-
117-
source coreModules*.javadoc*.source
118-
classpath = files(coreModules*.javadoc*.classpath)
119-
}
120-
121-
task docsZip(type: Zip, dependsOn: asciidoctor) {
122-
group = "Distribution"
123-
baseName = "spring-ldap"
124-
classifier = "docs"
125-
description = "Builds -${classifier} archive containing api and reference " +
126-
"for deployment at https://docs.spring.io/spring-ldap/docs."
127-
128-
from("src/dist") {
129-
include "changelog.txt"
130-
}
131-
132-
from (api) {
133-
into "apidocs"
134-
}
135-
136-
from (new File(asciidoctor.outputDir, "html5")) {
137-
include "*.html"
138-
into "reference"
139-
}
140-
}
141-
142-
task schemaZip(type: Zip) {
143-
group = 'Distribution'
144-
baseName = rootProject.name
145-
classifier = 'schema'
146-
description = "Builds -${classifier} archive containing all " +
147-
"XSDs for deployment at static.springframework.org/schema."
148-
149-
coreModules.each { module ->
150-
def Properties schemas = new Properties();
151-
152-
module.sourceSets.main.resources.find {
153-
it.path.endsWith('META-INF/spring.schemas')
154-
}?.withInputStream { schemas.load(it) }
155-
156-
for (def key : schemas.keySet()) {
157-
def shortName = key.replaceAll(/http.*schema.(.*).spring-.*/, '$1')
158-
assert shortName != key
159-
File xsdFile = module.sourceSets.main.resources.find {
160-
it.path.endsWith(schemas.get(key))
161-
}
162-
assert xsdFile != null
163-
into (shortName) {
164-
duplicatesStrategy 'exclude'
165-
from xsdFile.path
166-
}
167-
}
168-
}
169-
}
170-
171-
172-
task distZip(type: Zip, dependsOn: [docsZip]) {
173-
dependsOn subprojects*.tasks*.matching { task -> task.name == 'assemble' }
174-
175-
group = "Distribution"
176-
baseName = "spring-ldap"
177-
classifier = "dist"
178-
description = "Builds -${classifier} archive, containing all jars and docs, " +
179-
"suitable for community download page."
180-
181-
ext.baseDir = "${baseName}-${project.version}"
182-
183-
184-
from("src/dist") {
185-
include "readme.md"
186-
include "license.txt"
187-
include "notice.txt"
188-
into "${baseDir}"
189-
expand(copyright: new Date().format("yyyy"), version: project.version)
190-
}
191-
192-
from(zipTree(docsZip.archivePath)) {
193-
into "${baseDir}/docs"
194-
}
195-
196-
coreModules.each { subproject ->
197-
into ("${baseDir}/libs") {
198-
from subproject.jar
199-
if (subproject.tasks.findByPath("sourcesJar")) {
200-
from subproject.sourcesJar
201-
}
202-
if (subproject.tasks.findByPath("javadocJar")) {
203-
from subproject.javadocJar
204-
}
205-
}
206-
}
207-
}
208-
209-
artifacts {
210-
archives docsZip
211-
archives distZip
212-
archives schemaZip
213-
}
214-
215-
216-
if (project.hasProperty('artifactoryUsername')) {
217-
allprojects { project ->
218-
project.repositories { repos ->
219-
all { repo ->
220-
if (!repo.url.toString().startsWith("https://repo.spring.io/")) {
221-
return;
222-
}
223-
repo.credentials {
224-
username = artifactoryUsername
225-
password = artifactoryPassword
226-
}
227-
}
228-
}
229-
}
230-
}

buildSrc/build.gradle

Lines changed: 113 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,117 @@
1-
description = "Exposes gradle buildSrc for IDE support"
2-
apply plugin: "groovy"
1+
plugins {
2+
id "java-gradle-plugin"
3+
id "java"
4+
id "groovy"
5+
id 'com.apollographql.apollo' version '2.4.5'
6+
}
7+
8+
sourceCompatibility = JavaVersion.VERSION_11
9+
10+
repositories {
11+
gradlePluginPortal()
12+
mavenCentral()
13+
maven { url 'https://repo.spring.io/plugins-release/' }
14+
}
15+
16+
sourceSets {
17+
main {
18+
java {
19+
srcDirs = []
20+
}
21+
groovy {
22+
srcDirs += ["src/main/java"]
23+
}
24+
}
25+
}
26+
27+
gradlePlugin {
28+
plugins {
29+
checkAntoraVersion {
30+
id = "org.springframework.antora.check-version"
31+
implementationClass = "org.springframework.gradle.antora.CheckAntoraVersionPlugin"
32+
}
33+
trang {
34+
id = "trang"
35+
implementationClass = "trang.TrangPlugin"
36+
}
37+
locks {
38+
id = "locks"
39+
implementationClass = "lock.GlobalLockPlugin"
40+
}
41+
managementConfiguration {
42+
id = "io.spring.convention.management-configuration"
43+
implementationClass = "io.spring.gradle.convention.ManagementConfigurationPlugin"
44+
}
45+
updateDependencies {
46+
id = "org.springframework.security.update-dependencies"
47+
implementationClass = "org.springframework.security.convention.versions.UpdateDependenciesPlugin"
48+
}
49+
sagan {
50+
id = "org.springframework.security.sagan"
51+
implementationClass = "org.springframework.gradle.sagan.SaganPlugin"
52+
}
53+
githubMilestone {
54+
id = "org.springframework.github.milestone"
55+
implementationClass = "org.springframework.gradle.github.milestones.GitHubMilestonePlugin"
56+
}
57+
githubChangelog {
58+
id = "org.springframework.github.changelog"
59+
implementationClass = "org.springframework.gradle.github.changelog.GitHubChangelogPlugin"
60+
}
61+
githubRelease {
62+
id = "org.springframework.github.release"
63+
implementationClass = "org.springframework.gradle.github.release.GitHubReleasePlugin"
64+
}
65+
s101 {
66+
id = "s101"
67+
implementationClass = "s101.S101Plugin"
68+
}
69+
}
70+
}
71+
72+
configurations {
73+
implementation {
74+
exclude module: 'groovy-all'
75+
}
76+
}
377

478
dependencies {
5-
implementation gradleApi()
79+
implementation 'com.google.code.gson:gson:2.8.6'
80+
implementation 'com.thaiopensource:trang:20091111'
81+
implementation 'net.sourceforge.saxon:saxon:9.1.0.8'
82+
implementation 'org.yaml:snakeyaml:1.30'
683
implementation localGroovy()
84+
85+
implementation 'io.github.gradle-nexus:publish-plugin:1.1.0'
86+
implementation 'io.projectreactor:reactor-core:3.4.11'
87+
implementation 'org.gretty:gretty:4.0.0'
88+
implementation 'com.apollographql.apollo:apollo-runtime:2.4.5'
89+
implementation 'com.github.ben-manes:gradle-versions-plugin:0.38.0'
90+
implementation 'com.github.spullara.mustache.java:compiler:0.9.4'
91+
implementation 'io.spring.javaformat:spring-javaformat-gradle-plugin:0.0.15'
92+
implementation 'io.spring.nohttp:nohttp-gradle:0.0.10'
93+
implementation 'net.sourceforge.htmlunit:htmlunit:2.37.0'
94+
implementation 'org.hidetake:gradle-ssh-plugin:2.10.1'
95+
implementation 'org.jfrog.buildinfo:build-info-extractor-gradle:4.26.1'
96+
implementation 'org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.7.1'
97+
98+
testImplementation platform('org.junit:junit-bom:5.8.1')
99+
testImplementation "org.junit.jupiter:junit-jupiter-api"
100+
testImplementation "org.junit.jupiter:junit-jupiter-params"
101+
testImplementation "org.junit.jupiter:junit-jupiter-engine"
102+
testImplementation 'org.apache.commons:commons-io:1.3.2'
103+
testImplementation 'org.assertj:assertj-core:3.13.2'
104+
testImplementation 'org.mockito:mockito-core:3.12.4'
105+
testImplementation 'org.mockito:mockito-junit-jupiter:3.12.4'
106+
testImplementation "com.squareup.okhttp3:mockwebserver:3.14.9"
107+
}
108+
109+
110+
tasks.named('test', Test).configure {
111+
onlyIf { !project.hasProperty("buildSrc.skipTests") }
112+
useJUnitPlatform()
113+
jvmArgs(
114+
'--add-opens', 'java.base/java.lang=ALL-UNNAMED',
115+
'--add-opens', 'java.base/java.util=ALL-UNNAMED'
116+
)
7117
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
mutation CreateIssueInput($assigneeId: ID!, $labelIds: [ID!], $milestoneId: ID!, $repositoryId: ID!, $title: String!) {
2+
createIssue(input: {assigneeIds: [$assigneeId], labelIds: $labelIds, milestoneId: $milestoneId, projectIds: [], repositoryId: $repositoryId, title: $title}) {
3+
issue {
4+
number
5+
}
6+
}
7+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
query FindCreateIssueInput($owner: String!, $name: String!, $labelQuery: String, $milestoneName: String) {
2+
repository(owner: $owner, name: $name) {
3+
id
4+
labels(query: $labelQuery, first: 1) {
5+
nodes {
6+
id
7+
name
8+
}
9+
}
10+
milestones(query: $milestoneName, states: [OPEN], first: 1) {
11+
nodes {
12+
id
13+
title
14+
}
15+
}
16+
}
17+
viewer {
18+
id
19+
}
20+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
query RateLimit {
2+
rateLimit {
3+
limit
4+
cost
5+
remaining
6+
resetAt
7+
}
8+
}

buildSrc/src/main/graphql/org/springframework/security/convention/versions/schema.json

Lines changed: 1 addition & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)