Remove Jenkins pipeline
This commit removes the Jenkins pipeline in preparation to the move to GitHub Actions. See gh-1461
This commit is contained in:
325
Jenkinsfile
vendored
325
Jenkinsfile
vendored
@@ -1,325 +0,0 @@
|
||||
def p = [:]
|
||||
node {
|
||||
checkout scm
|
||||
p = readProperties interpolate: true, file: 'ci/pipeline.properties'
|
||||
}
|
||||
|
||||
pipeline {
|
||||
agent none
|
||||
|
||||
triggers {
|
||||
pollSCM 'H/10 * * * *'
|
||||
}
|
||||
|
||||
options {
|
||||
disableConcurrentBuilds()
|
||||
buildDiscarder(logRotator(numToKeepStr: '14'))
|
||||
}
|
||||
|
||||
stages {
|
||||
stage('Publish Eclipse Temurin (main) + gpg docker image') {
|
||||
when {
|
||||
changeset "ci/Dockerfile"
|
||||
}
|
||||
agent any
|
||||
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
def image = docker.build("${p['docker.java.build.image']}", "ci/")
|
||||
image.push()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stage("Test: baseline (main)") {
|
||||
agent any
|
||||
options { timeout(time: 30, unit: 'MINUTES')}
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
sh "PROFILE=jakarta-ee-10,distribute,convergence ci/test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("Test other configurations") {
|
||||
when {
|
||||
beforeAgent(true)
|
||||
branch(pattern: "main|(\\d\\.\\d\\.x)|release(-.+)?|issue/.+", comparator: "REGEXP")
|
||||
}
|
||||
|
||||
parallel {
|
||||
stage("Test: spring-buildsnapshot (main)") {
|
||||
agent any
|
||||
options { timeout(time: 30, unit: 'MINUTES')}
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
sh "PROFILE=jakarta-ee-10,spring-buildsnapshot,convergence ci/test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("Test: wss4j-next (main)") {
|
||||
agent any
|
||||
options { timeout(time: 30, unit: 'MINUTES')}
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
sh "PROFILE=jakarta-ee-10,wss4j-next,convergence ci/test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("Test: spring-next-gen (main)") {
|
||||
agent any
|
||||
options { timeout(time: 30, unit: 'MINUTES')}
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
sh "PROFILE=jakarta-ee-10,spring-next-gen,convergence ci/test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("Test: spring-next-gen-snapshot (main)") {
|
||||
agent any
|
||||
options { timeout(time: 30, unit: 'MINUTES')}
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
sh "PROFILE=jakarta-ee-10,spring-next-gen-snapshot,convergence ci/test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("Test: jakarta-ee-9 (main)") {
|
||||
agent any
|
||||
options { timeout(time: 30, unit: 'MINUTES')}
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
// Active Jakarta EE 9 profile and disable Jakarta EE 10 (default) profile
|
||||
sh "PROFILE=jakarta-ee-9,-jakarta-ee-10,convergence ci/test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Deploy') {
|
||||
agent any
|
||||
options { timeout(time: 20, unit: 'MINUTES') }
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
SONATYPE = credentials('oss-login')
|
||||
KEYRING = credentials('spring-signing-secring.gpg')
|
||||
PASSPHRASE = credentials('spring-gpg-passphrase')
|
||||
STAGING_PROFILE_ID = credentials('spring-data-release-deployment-maven-central-staging-profile-id')
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image("${p['docker.java.build.image-proxy']}").inside(p['docker.java.inside.basic']) {
|
||||
PROJECT_VERSION = sh(
|
||||
script: "ci/version.sh",
|
||||
returnStdout: true
|
||||
).trim()
|
||||
|
||||
echo "Releasing Spring WS ${PROJECT_VERSION}..."
|
||||
|
||||
if (PROJECT_VERSION.matches(/.*-RC[0-9]+$/) || PROJECT_VERSION.matches(/.*-M[0-9]+$/)) {
|
||||
RELEASE_TYPE = "milestone"
|
||||
} else if (PROJECT_VERSION.endsWith('SNAPSHOT')) {
|
||||
RELEASE_TYPE = 'snapshot'
|
||||
} else if (PROJECT_VERSION.matches(/.*\.[0-9]+$/)) {
|
||||
RELEASE_TYPE = 'release'
|
||||
} else {
|
||||
RELEASE_TYPE = 'snapshot'
|
||||
}
|
||||
|
||||
echo "Release type: ${RELEASE_TYPE}"
|
||||
|
||||
if (RELEASE_TYPE == 'release') {
|
||||
|
||||
STAGING_REPOSITORY_ID = sh(
|
||||
script: "ci/rc-open.sh",
|
||||
returnStdout: true
|
||||
).readLines()
|
||||
.findAll{ line -> line.contains("<repository>") && !line.contains("%s") }
|
||||
.collect{ s -> s.substring(s.indexOf("<repository>") + "<repository>".length(), s.indexOf("</repository>")) }
|
||||
.inject(0){ first, second -> second } // find the last entry, a.k.a. the most recent staging repository id
|
||||
|
||||
sh "ci/build-and-deploy-to-maven-central.sh ${PROJECT_VERSION} ${STAGING_REPOSITORY_ID}"
|
||||
sh "ci/rc-close.sh ${STAGING_REPOSITORY_ID}"
|
||||
// sh "ci/smoke-test-against-maven-central.sh ${PROJECT_VERSION} ${STAGING_REPOSITORY_ID}"
|
||||
|
||||
writeFile(file: 'staging_repository_id.txt', text: "${STAGING_REPOSITORY_ID}")
|
||||
stash 'staging_repository_id.txt'
|
||||
|
||||
} else {
|
||||
|
||||
sh "ci/build-and-deploy-to-artifactory.sh ${RELEASE_TYPE}"
|
||||
|
||||
// TODO: Resolve smoke testing against Artifactory
|
||||
// sh "ci/smoke-test-against-artifactory.sh ${PROJECT_VERSION}"
|
||||
|
||||
if (RELEASE_TYPE == 'milestone') {
|
||||
slackSend(
|
||||
color: (currentBuild.currentResult == 'SUCCESS') ? 'good' : 'danger',
|
||||
channel: '#spring-ws',
|
||||
message: "Spring WS ${PROJECT_VERSION} is released to Artifactory!")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Deploy (part 2)') {
|
||||
agent any
|
||||
options { timeout(time: 20, unit: 'MINUTES') }
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
SONATYPE = credentials('oss-login')
|
||||
KEYRING = credentials('spring-signing-secring.gpg')
|
||||
PASSPHRASE = credentials('spring-gpg-passphrase')
|
||||
STAGING_PROFILE_ID = credentials('spring-data-release-deployment-maven-central-staging-profile-id')
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image("${p['docker.java.legacy.image']}").inside(p['docker.java.inside.basic']) {
|
||||
PROJECT_VERSION = sh(
|
||||
script: "ci/version.sh",
|
||||
returnStdout: true
|
||||
).trim()
|
||||
|
||||
echo "Releasing Spring WS ${PROJECT_VERSION}..."
|
||||
|
||||
if (PROJECT_VERSION.matches(/.*-RC[0-9]+$/) || PROJECT_VERSION.matches(/.*-M[0-9]+$/)) {
|
||||
RELEASE_TYPE = "milestone"
|
||||
} else if (PROJECT_VERSION.endsWith('SNAPSHOT')) {
|
||||
RELEASE_TYPE = 'snapshot'
|
||||
} else if (PROJECT_VERSION.matches(/.*\.[0-9]+$/)) {
|
||||
RELEASE_TYPE = 'release'
|
||||
} else {
|
||||
RELEASE_TYPE = 'snapshot'
|
||||
}
|
||||
|
||||
echo "Release type: ${RELEASE_TYPE}"
|
||||
|
||||
if (RELEASE_TYPE == 'release') {
|
||||
|
||||
unstash 'staging_repository_id.txt'
|
||||
|
||||
def STAGING_REPOSITORY_ID = readFile(file: 'staging_repository_id.txt')
|
||||
|
||||
sh "ci/rc-release.sh ${STAGING_REPOSITORY_ID}"
|
||||
|
||||
slackSend(
|
||||
color: (currentBuild.currentResult == 'SUCCESS') ? 'good' : 'danger',
|
||||
channel: '#spring-ws',
|
||||
message: "Spring WS ${PROJECT_VERSION} is released to Maven Central!")
|
||||
} else {
|
||||
|
||||
echo "Since this is an Artifactory release, there is no 'part 2'."
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Release documentation') {
|
||||
when {
|
||||
beforeAgent(true)
|
||||
branch(pattern: "main|release", comparator: "REGEXP")
|
||||
}
|
||||
agent any
|
||||
options { timeout(time: 20, unit: 'MINUTES') }
|
||||
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry('', "${p['dockerhub.credentials']}") {
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.basic']) {
|
||||
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ' +
|
||||
'./mvnw -s settings.xml -Pjakarta-ee-10,distribute,docs ' +
|
||||
'-Dartifactory.server=https://repo.spring.io ' +
|
||||
"-Dartifactory.username=${ARTIFACTORY_USR} " +
|
||||
"-Dartifactory.password=${ARTIFACTORY_PSW} " +
|
||||
"-Dartifactory.distribution-repository=temp-private-local " +
|
||||
'-Duser.name=spring-builds+jenkins -Dmaven.test.skip=true -Dmaven.deploy.skip=true deploy -B'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
post {
|
||||
changed {
|
||||
script {
|
||||
slackSend(
|
||||
color: (currentBuild.currentResult == 'SUCCESS') ? 'good' : 'danger',
|
||||
channel: '#spring-ws',
|
||||
message: "${currentBuild.fullDisplayName} - `${currentBuild.currentResult}`\n${env.BUILD_URL}")
|
||||
emailext(
|
||||
subject: "[${currentBuild.fullDisplayName}] ${currentBuild.currentResult}",
|
||||
mimeType: 'text/html',
|
||||
recipientProviders: [[$class: 'CulpritsRecipientProvider'], [$class: 'RequesterRecipientProvider']],
|
||||
body: "<a href=\"${env.BUILD_URL}\">${currentBuild.fullDisplayName} is reported as ${currentBuild.currentResult}</a>")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
104
README.adoc
104
README.adoc
@@ -3,7 +3,6 @@ image:https://spring.io/img/projects/logo-web-services.svg["Spring Web Services"
|
||||
|
||||
= Spring Web Services
|
||||
|
||||
image:https://jenkins.spring.io/buildStatus/icon?job=spring-ws%2Fmain)[link='https://jenkins.spring.io/job/spring-ws/job/main/']
|
||||
|
||||
|
||||
Spring Web Services is a product of the Spring community focused on creating
|
||||
@@ -26,109 +25,6 @@ This will generate the artifacts.
|
||||
|
||||
You can also import the project into your IDE.
|
||||
|
||||
== Making a release
|
||||
|
||||
Before you make a release, follow this checklist:
|
||||
|
||||
* Are you using the latest milestone/release candidate/release of Spring Framework? If not, upgrade. (Don't forget `spring-buildsnapshot` profile.)
|
||||
* Are you using the latest milestone/release candidate/release of Spring Security? If not, upgrade. (Don't forget `spring-buildsnapshot` profile.)
|
||||
* Are you set up with the right version of Java? If not switch. (Java 17 for 4.0+, Java 8 for everything else.)
|
||||
* Is it time to switch from milestone to release candidate? Or from release candidate to release?
|
||||
|
||||
NOTE: The _actual_ building and releasing is done on CI inside a Docker container, ensuring little risk between versions of Java.
|
||||
But part of the release process requires a local check, which DOES depend upon your environment.
|
||||
|
||||
. Create a new release (on the main branch).
|
||||
+
|
||||
[source,shell]
|
||||
----
|
||||
% ci/create-release.sh <release version> <next snapshot version>
|
||||
----
|
||||
+
|
||||
. With the release tagged, update the release branch to the newly created tag.
|
||||
+
|
||||
[source,shell]
|
||||
----
|
||||
% git checkout release
|
||||
% git reset --hard <tag>
|
||||
----
|
||||
+
|
||||
. Verify this builds locally and passes all tests.
|
||||
+
|
||||
[source,shell]
|
||||
----
|
||||
% ./mvnw clean package
|
||||
% ./mvnw -Pspring-buildsnapshot clean package
|
||||
% ./mvnw -Pspring-next-gen clean package
|
||||
% ./mvnw -Pspring-next-gen-snapshot clean package
|
||||
----
|
||||
+
|
||||
. Push the tagged version to the release branch.
|
||||
+
|
||||
[source,shell]
|
||||
----
|
||||
% git push -f origin release
|
||||
----
|
||||
+
|
||||
. Once completed, push the `main` branch for next version's snapshots.
|
||||
+
|
||||
[source,shell]
|
||||
----
|
||||
% git checkout main
|
||||
% git push
|
||||
% git push --tags
|
||||
----
|
||||
|
||||
The pipeline will build and release the "release" branch on artifactory for milestones and RCs.
|
||||
For releases, they are sent to maven central.
|
||||
|
||||
Once the release is completed and tags are pushed:
|
||||
|
||||
. Close the GitHub issue milestone.
|
||||
. Run the `ChangeLogCreator` report against that milestone.
|
||||
. Go to https://github.com/spring-projects/spring-ws/releases.
|
||||
. Find that tag and create a new release. Use the output from `ChangeLogCreator` as the content for the release report.
|
||||
. Announce on #spring-release.
|
||||
|
||||
=== Running CI tasks locally
|
||||
|
||||
Since the pipeline uses Docker, it's easy to:
|
||||
|
||||
* Debug what went wrong on your local machine.
|
||||
* Test out a tweak to your `test.sh` script before sending it out.
|
||||
* Experiment against a new image before submitting your pull request.
|
||||
|
||||
All of these use cases are great reasons to know what Jenkins does, on your local machine.
|
||||
|
||||
IMPORTANT: To do this you must have Docker installed on your machine.
|
||||
|
||||
1. `docker run -it --mount type=bind,source="$(pwd)",target=/spring-ws-github openjdk:17-bullseye /bin/bash`
|
||||
+
|
||||
This will launch the Docker image and mount your source code at `spring-ws-github`.
|
||||
+
|
||||
2. `cd spring-ws-github`
|
||||
+
|
||||
Next, run the `test.sh` script from inside the container:
|
||||
+
|
||||
3. `PROFILE=none ci/test.sh`
|
||||
|
||||
Since the container is binding to your source, you can make edits from your IDE and continue to run build jobs.
|
||||
|
||||
If you need to test the `build.sh` script, then do this:
|
||||
|
||||
1. `docker run -it --mount type=bind,source="$(pwd)",target=/spring-ws-github openjdk:17-bullseye /bin/bash`
|
||||
+
|
||||
This will launch the Docker image and mount your source code at `spring-ws-github` and the temporary
|
||||
artifactory output directory at `spring-ws-artifactory`.
|
||||
+
|
||||
Next, run the `build.sh` script from inside the container:
|
||||
+
|
||||
2. `ci/build.sh`
|
||||
|
||||
IMPORTANT: `build.sh` will attempt to push to Artifactory. If you don't supply credentials, it will fail.
|
||||
|
||||
NOTE: Docker containers can eat up disk space fast! From time to time, run `docker system prune` to clean out old images.
|
||||
|
||||
== Code of Conduct
|
||||
|
||||
This project adheres to the Contributor Covenant link:CODE_OF_CONDUCT.adoc[code of conduct].
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
FROM eclipse-temurin:17-jdk-jammy
|
||||
|
||||
RUN apt-get update && apt-get install -y gpg
|
||||
|
||||
RUN apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
@@ -1,13 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
RELEASE_TYPE=$1
|
||||
|
||||
echo 'Deploying to Artifactory...'
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
-s settings.xml \
|
||||
-Pjakarta-ee-10,distribute,${RELEASE_TYPE} \
|
||||
-Dmaven.test.skip=true \
|
||||
clean deploy -B
|
||||
@@ -1,25 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
PROJECT_VERSION=$1
|
||||
STAGING_REPOSITORY_ID=$2
|
||||
|
||||
echo 'Staging on Maven Central...'
|
||||
|
||||
GNUPGHOME=/tmp/gpghome
|
||||
export GNUPGHOME
|
||||
|
||||
mkdir $GNUPGHOME
|
||||
cp $KEYRING $GNUPGHOME
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
-s settings.xml \
|
||||
-Pjakarta-ee-10,distribute,central \
|
||||
-Dmaven.test.skip=true \
|
||||
-Dgpg.passphrase=${PASSPHRASE} \
|
||||
-Dgpg.secretKeyring=${GNUPGHOME}/secring.gpg \
|
||||
-DstagingDescription="Releasing ${PROJECT_VERSION}" \
|
||||
-DstagingRepositoryId="${STAGING_REPOSITORY_ID}" \
|
||||
clean deploy -B
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
RELEASE=$1
|
||||
SNAPSHOT=$2
|
||||
|
||||
# Bump up the version in pom.xml to the desired version and commit the change
|
||||
./mvnw versions:set -DnewVersion=$RELEASE -DgenerateBackupPoms=false -DprocessAllModules=true -DoldVersion='*'
|
||||
git add .
|
||||
git commit --message "Releasing Spring Web Services v$RELEASE"
|
||||
|
||||
# Tag the release
|
||||
git tag -s v$RELEASE -m "v$RELEASE"
|
||||
|
||||
# Bump up the version in pom.xml to the next snapshot
|
||||
./mvnw versions:set -DnewVersion=$SNAPSHOT -DgenerateBackupPoms=false -DprocessAllModules=true -DoldVersion='*'
|
||||
git add .
|
||||
git commit --message "Continue development on v$SNAPSHOT"
|
||||
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
# Java versions
|
||||
java.legacy.tag=8-jdk-focal
|
||||
java.main.tag=17-jdk-jammy
|
||||
java.next.tag=21-jdk-jammy
|
||||
|
||||
# Docker container images - standard
|
||||
docker.java.legacy.image=library/eclipse-temurin:${java.legacy.tag}
|
||||
docker.java.main.image=library/eclipse-temurin:${java.main.tag}
|
||||
docker.java.next.image=library/eclipse-temurin:${java.next.tag}
|
||||
|
||||
# Docker container images - for release
|
||||
docker.java.build.image=springci/spring-ws-eclipse-temurin-with-gpg:${java.main.tag}
|
||||
docker.java.build.image-proxy=${docker.java.build.image}
|
||||
|
||||
# Docker environment settings
|
||||
docker.java.inside.basic=-v $HOME:/tmp/jenkins-home
|
||||
|
||||
# Credentials
|
||||
artifactory.credentials=02bd1690-b54f-4c9f-819d-a77cb7a9822c
|
||||
dockerhub.credentials=hub.docker.com-springbuildmaster
|
||||
develocity.access-key=gradle_enterprise_secret_access_key
|
||||
@@ -1,14 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
STAGING_PROFILE_ID=$1
|
||||
|
||||
echo 'Closing remote repository on Maven Central...'
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
-s settings.xml \
|
||||
-Pcentral \
|
||||
-DstagingRepositoryId=${STAGING_PROFILE_ID} \
|
||||
nexus-staging:rc-close
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
echo "Opening a remote repository for this release..."
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
-s settings.xml \
|
||||
-Pcentral \
|
||||
-DstagingProfileId=${STAGING_PROFILE_ID} \
|
||||
-DopenedRepositoryMessageFormat="<repository>%s</repository>" \
|
||||
nexus-staging:rc-open
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
STAGING_REPOSITORY_ID=$1
|
||||
|
||||
echo 'Release to Maven central...'
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home " ./mvnw \
|
||||
-s settings.xml \
|
||||
-Pcentral \
|
||||
-DstagingRepositoryId="${STAGING_REPOSITORY_ID}" \
|
||||
nexus-staging:rc-release
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
PROJECT_VERSION=$1
|
||||
|
||||
echo 'Smoke test against Artifactory...'
|
||||
|
||||
cd smoke-tests
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
-Partifactory \
|
||||
-Dspring-ws.version="${PROJECT_VERSION}" \
|
||||
clean dependency:purge-local-repository verify -B -U
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
PROJECT_VERSION=$1
|
||||
STAGING_REPOSITORY_ID=$2
|
||||
|
||||
echo 'Smoke test against Maven Central...'
|
||||
|
||||
cd smoke-tests
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
-Pmaven-central \
|
||||
-DstagingRepositoryId="${STAGING_REPOSITORY_ID}" \
|
||||
-Dspring-ws.version="${PROJECT_VERSION}" \
|
||||
clean dependency:purge-local-repository verify -B -U
|
||||
|
||||
echo "Smoke tests passed. Don't smoke!"
|
||||
@@ -1,7 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" \
|
||||
./mvnw -s settings.xml \
|
||||
-P${PROFILE} clean dependency:list test -Dsort -B -U
|
||||
@@ -1,10 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
VERSION=`MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
|
||||
org.apache.maven.plugins:maven-help-plugin:3.4.0:evaluate \
|
||||
-Dexpression=project.version -q -DforceStdout | tail -1`
|
||||
|
||||
echo $VERSION
|
||||
|
||||
BIN
smoke-tests/.mvn/wrapper/maven-wrapper.jar
vendored
BIN
smoke-tests/.mvn/wrapper/maven-wrapper.jar
vendored
Binary file not shown.
@@ -1,2 +0,0 @@
|
||||
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.1/apache-maven-3.9.1-bin.zip
|
||||
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
|
||||
316
smoke-tests/mvnw
vendored
316
smoke-tests/mvnw
vendored
@@ -1,316 +0,0 @@
|
||||
#!/bin/sh
|
||||
# ----------------------------------------------------------------------------
|
||||
# Licensed to the Apache Software Foundation (ASF) under one
|
||||
# or more contributor license agreements. See the NOTICE file
|
||||
# distributed with this work for additional information
|
||||
# regarding copyright ownership. The ASF licenses this file
|
||||
# to you under the Apache License, Version 2.0 (the
|
||||
# "License"); you may not use this file except in compliance
|
||||
# with the License. You may obtain a copy of the License at
|
||||
#
|
||||
# https://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
# Maven Start Up Batch script
|
||||
#
|
||||
# Required ENV vars:
|
||||
# ------------------
|
||||
# JAVA_HOME - location of a JDK home dir
|
||||
#
|
||||
# Optional ENV vars
|
||||
# -----------------
|
||||
# M2_HOME - location of maven2's installed home dir
|
||||
# MAVEN_OPTS - parameters passed to the Java VM when running Maven
|
||||
# e.g. to debug Maven itself, use
|
||||
# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
|
||||
# MAVEN_SKIP_RC - flag to disable loading of mavenrc files
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
if [ -z "$MAVEN_SKIP_RC" ] ; then
|
||||
|
||||
if [ -f /usr/local/etc/mavenrc ] ; then
|
||||
. /usr/local/etc/mavenrc
|
||||
fi
|
||||
|
||||
if [ -f /etc/mavenrc ] ; then
|
||||
. /etc/mavenrc
|
||||
fi
|
||||
|
||||
if [ -f "$HOME/.mavenrc" ] ; then
|
||||
. "$HOME/.mavenrc"
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
# OS specific support. $var _must_ be set to either true or false.
|
||||
cygwin=false;
|
||||
darwin=false;
|
||||
mingw=false
|
||||
case "`uname`" in
|
||||
CYGWIN*) cygwin=true ;;
|
||||
MINGW*) mingw=true;;
|
||||
Darwin*) darwin=true
|
||||
# Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home
|
||||
# See https://developer.apple.com/library/mac/qa/qa1170/_index.html
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
if [ -x "/usr/libexec/java_home" ]; then
|
||||
export JAVA_HOME="`/usr/libexec/java_home`"
|
||||
else
|
||||
export JAVA_HOME="/Library/Java/Home"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -z "$JAVA_HOME" ] ; then
|
||||
if [ -r /etc/gentoo-release ] ; then
|
||||
JAVA_HOME=`java-config --jre-home`
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -z "$M2_HOME" ] ; then
|
||||
## resolve links - $0 may be a link to maven's home
|
||||
PRG="$0"
|
||||
|
||||
# need this for relative symlinks
|
||||
while [ -h "$PRG" ] ; do
|
||||
ls=`ls -ld "$PRG"`
|
||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
||||
if expr "$link" : '/.*' > /dev/null; then
|
||||
PRG="$link"
|
||||
else
|
||||
PRG="`dirname "$PRG"`/$link"
|
||||
fi
|
||||
done
|
||||
|
||||
saveddir=`pwd`
|
||||
|
||||
M2_HOME=`dirname "$PRG"`/..
|
||||
|
||||
# make it fully qualified
|
||||
M2_HOME=`cd "$M2_HOME" && pwd`
|
||||
|
||||
cd "$saveddir"
|
||||
# echo Using m2 at $M2_HOME
|
||||
fi
|
||||
|
||||
# For Cygwin, ensure paths are in UNIX format before anything is touched
|
||||
if $cygwin ; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME=`cygpath --unix "$M2_HOME"`
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
||||
[ -n "$CLASSPATH" ] &&
|
||||
CLASSPATH=`cygpath --path --unix "$CLASSPATH"`
|
||||
fi
|
||||
|
||||
# For Mingw, ensure paths are in UNIX format before anything is touched
|
||||
if $mingw ; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME="`(cd "$M2_HOME"; pwd)`"
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME="`(cd "$JAVA_HOME"; pwd)`"
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
javaExecutable="`which javac`"
|
||||
if [ -n "$javaExecutable" ] && ! [ "`expr \"$javaExecutable\" : '\([^ ]*\)'`" = "no" ]; then
|
||||
# readlink(1) is not available as standard on Solaris 10.
|
||||
readLink=`which readlink`
|
||||
if [ ! `expr "$readLink" : '\([^ ]*\)'` = "no" ]; then
|
||||
if $darwin ; then
|
||||
javaHome="`dirname \"$javaExecutable\"`"
|
||||
javaExecutable="`cd \"$javaHome\" && pwd -P`/javac"
|
||||
else
|
||||
javaExecutable="`readlink -f \"$javaExecutable\"`"
|
||||
fi
|
||||
javaHome="`dirname \"$javaExecutable\"`"
|
||||
javaHome=`expr "$javaHome" : '\(.*\)/bin'`
|
||||
JAVA_HOME="$javaHome"
|
||||
export JAVA_HOME
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -z "$JAVACMD" ] ; then
|
||||
if [ -n "$JAVA_HOME" ] ; then
|
||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||
# IBM's JDK on AIX uses strange locations for the executables
|
||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
||||
else
|
||||
JAVACMD="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
else
|
||||
JAVACMD="`\\unset -f command; \\command -v java`"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ ! -x "$JAVACMD" ] ; then
|
||||
echo "Error: JAVA_HOME is not defined correctly." >&2
|
||||
echo " We cannot execute $JAVACMD" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA_HOME" ] ; then
|
||||
echo "Warning: JAVA_HOME environment variable is not set."
|
||||
fi
|
||||
|
||||
CLASSWORLDS_LAUNCHER=org.codehaus.plexus.classworlds.launcher.Launcher
|
||||
|
||||
# traverses directory structure from process work directory to filesystem root
|
||||
# first directory with .mvn subdirectory is considered project base directory
|
||||
find_maven_basedir() {
|
||||
|
||||
if [ -z "$1" ]
|
||||
then
|
||||
echo "Path not specified to find_maven_basedir"
|
||||
return 1
|
||||
fi
|
||||
|
||||
basedir="$1"
|
||||
wdir="$1"
|
||||
while [ "$wdir" != '/' ] ; do
|
||||
if [ -d "$wdir"/.mvn ] ; then
|
||||
basedir=$wdir
|
||||
break
|
||||
fi
|
||||
# workaround for JBEAP-8937 (on Solaris 10/Sparc)
|
||||
if [ -d "${wdir}" ]; then
|
||||
wdir=`cd "$wdir/.."; pwd`
|
||||
fi
|
||||
# end of workaround
|
||||
done
|
||||
echo "${basedir}"
|
||||
}
|
||||
|
||||
# concatenates all lines of a file
|
||||
concat_lines() {
|
||||
if [ -f "$1" ]; then
|
||||
echo "$(tr -s '\n' ' ' < "$1")"
|
||||
fi
|
||||
}
|
||||
|
||||
BASE_DIR=`find_maven_basedir "$(pwd)"`
|
||||
if [ -z "$BASE_DIR" ]; then
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
##########################################################################################
|
||||
# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
|
||||
# This allows using the maven wrapper in projects that prohibit checking in binary data.
|
||||
##########################################################################################
|
||||
if [ -r "$BASE_DIR/.mvn/wrapper/maven-wrapper.jar" ]; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found .mvn/wrapper/maven-wrapper.jar"
|
||||
fi
|
||||
else
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Couldn't find .mvn/wrapper/maven-wrapper.jar, downloading it ..."
|
||||
fi
|
||||
if [ -n "$MVNW_REPOURL" ]; then
|
||||
jarUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
|
||||
else
|
||||
jarUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
|
||||
fi
|
||||
while IFS="=" read key value; do
|
||||
case "$key" in (wrapperUrl) jarUrl="$value"; break ;;
|
||||
esac
|
||||
done < "$BASE_DIR/.mvn/wrapper/maven-wrapper.properties"
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Downloading from: $jarUrl"
|
||||
fi
|
||||
wrapperJarPath="$BASE_DIR/.mvn/wrapper/maven-wrapper.jar"
|
||||
if $cygwin; then
|
||||
wrapperJarPath=`cygpath --path --windows "$wrapperJarPath"`
|
||||
fi
|
||||
|
||||
if command -v wget > /dev/null; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found wget ... using wget"
|
||||
fi
|
||||
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
|
||||
wget "$jarUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
|
||||
else
|
||||
wget --http-user=$MVNW_USERNAME --http-password=$MVNW_PASSWORD "$jarUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
|
||||
fi
|
||||
elif command -v curl > /dev/null; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found curl ... using curl"
|
||||
fi
|
||||
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
|
||||
curl -o "$wrapperJarPath" "$jarUrl" -f
|
||||
else
|
||||
curl --user $MVNW_USERNAME:$MVNW_PASSWORD -o "$wrapperJarPath" "$jarUrl" -f
|
||||
fi
|
||||
|
||||
else
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Falling back to using Java to download"
|
||||
fi
|
||||
javaClass="$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.java"
|
||||
# For Cygwin, switch paths to Windows format before running javac
|
||||
if $cygwin; then
|
||||
javaClass=`cygpath --path --windows "$javaClass"`
|
||||
fi
|
||||
if [ -e "$javaClass" ]; then
|
||||
if [ ! -e "$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.class" ]; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo " - Compiling MavenWrapperDownloader.java ..."
|
||||
fi
|
||||
# Compiling the Java class
|
||||
("$JAVA_HOME/bin/javac" "$javaClass")
|
||||
fi
|
||||
if [ -e "$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.class" ]; then
|
||||
# Running the downloader
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo " - Running MavenWrapperDownloader.java ..."
|
||||
fi
|
||||
("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$MAVEN_PROJECTBASEDIR")
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
##########################################################################################
|
||||
# End of extension
|
||||
##########################################################################################
|
||||
|
||||
export MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo $MAVEN_PROJECTBASEDIR
|
||||
fi
|
||||
MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS"
|
||||
|
||||
# For Cygwin, switch paths to Windows format before running java
|
||||
if $cygwin; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME=`cygpath --path --windows "$M2_HOME"`
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME=`cygpath --path --windows "$JAVA_HOME"`
|
||||
[ -n "$CLASSPATH" ] &&
|
||||
CLASSPATH=`cygpath --path --windows "$CLASSPATH"`
|
||||
[ -n "$MAVEN_PROJECTBASEDIR" ] &&
|
||||
MAVEN_PROJECTBASEDIR=`cygpath --path --windows "$MAVEN_PROJECTBASEDIR"`
|
||||
fi
|
||||
|
||||
# Provide a "standardized" way to retrieve the CLI args that will
|
||||
# work with both Windows and non-Windows executions.
|
||||
MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $@"
|
||||
export MAVEN_CMD_LINE_ARGS
|
||||
|
||||
WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
|
||||
|
||||
exec "$JAVACMD" \
|
||||
$MAVEN_OPTS \
|
||||
$MAVEN_DEBUG_OPTS \
|
||||
-classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
|
||||
"-Dmaven.home=${M2_HOME}" \
|
||||
"-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
|
||||
${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"
|
||||
188
smoke-tests/mvnw.cmd
vendored
188
smoke-tests/mvnw.cmd
vendored
@@ -1,188 +0,0 @@
|
||||
@REM ----------------------------------------------------------------------------
|
||||
@REM Licensed to the Apache Software Foundation (ASF) under one
|
||||
@REM or more contributor license agreements. See the NOTICE file
|
||||
@REM distributed with this work for additional information
|
||||
@REM regarding copyright ownership. The ASF licenses this file
|
||||
@REM to you under the Apache License, Version 2.0 (the
|
||||
@REM "License"); you may not use this file except in compliance
|
||||
@REM with the License. You may obtain a copy of the License at
|
||||
@REM
|
||||
@REM https://www.apache.org/licenses/LICENSE-2.0
|
||||
@REM
|
||||
@REM Unless required by applicable law or agreed to in writing,
|
||||
@REM software distributed under the License is distributed on an
|
||||
@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
@REM KIND, either express or implied. See the License for the
|
||||
@REM specific language governing permissions and limitations
|
||||
@REM under the License.
|
||||
@REM ----------------------------------------------------------------------------
|
||||
|
||||
@REM ----------------------------------------------------------------------------
|
||||
@REM Maven Start Up Batch script
|
||||
@REM
|
||||
@REM Required ENV vars:
|
||||
@REM JAVA_HOME - location of a JDK home dir
|
||||
@REM
|
||||
@REM Optional ENV vars
|
||||
@REM M2_HOME - location of maven2's installed home dir
|
||||
@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands
|
||||
@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending
|
||||
@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven
|
||||
@REM e.g. to debug Maven itself, use
|
||||
@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
|
||||
@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files
|
||||
@REM ----------------------------------------------------------------------------
|
||||
|
||||
@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on'
|
||||
@echo off
|
||||
@REM set title of command window
|
||||
title %0
|
||||
@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on'
|
||||
@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
|
||||
|
||||
@REM set %HOME% to equivalent of $HOME
|
||||
if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
|
||||
|
||||
@REM Execute a user defined script before this one
|
||||
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
|
||||
@REM check for pre script, once with legacy .bat ending and once with .cmd ending
|
||||
if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %*
|
||||
if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %*
|
||||
:skipRcPre
|
||||
|
||||
@setlocal
|
||||
|
||||
set ERROR_CODE=0
|
||||
|
||||
@REM To isolate internal variables from possible post scripts, we use another setlocal
|
||||
@setlocal
|
||||
|
||||
@REM ==== START VALIDATION ====
|
||||
if not "%JAVA_HOME%" == "" goto OkJHome
|
||||
|
||||
echo.
|
||||
echo Error: JAVA_HOME not found in your environment. >&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the >&2
|
||||
echo location of your Java installation. >&2
|
||||
echo.
|
||||
goto error
|
||||
|
||||
:OkJHome
|
||||
if exist "%JAVA_HOME%\bin\java.exe" goto init
|
||||
|
||||
echo.
|
||||
echo Error: JAVA_HOME is set to an invalid directory. >&2
|
||||
echo JAVA_HOME = "%JAVA_HOME%" >&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the >&2
|
||||
echo location of your Java installation. >&2
|
||||
echo.
|
||||
goto error
|
||||
|
||||
@REM ==== END VALIDATION ====
|
||||
|
||||
:init
|
||||
|
||||
@REM Find the project base dir, i.e. the directory that contains the folder ".mvn".
|
||||
@REM Fallback to current working directory if not found.
|
||||
|
||||
set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR%
|
||||
IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir
|
||||
|
||||
set EXEC_DIR=%CD%
|
||||
set WDIR=%EXEC_DIR%
|
||||
:findBaseDir
|
||||
IF EXIST "%WDIR%"\.mvn goto baseDirFound
|
||||
cd ..
|
||||
IF "%WDIR%"=="%CD%" goto baseDirNotFound
|
||||
set WDIR=%CD%
|
||||
goto findBaseDir
|
||||
|
||||
:baseDirFound
|
||||
set MAVEN_PROJECTBASEDIR=%WDIR%
|
||||
cd "%EXEC_DIR%"
|
||||
goto endDetectBaseDir
|
||||
|
||||
:baseDirNotFound
|
||||
set MAVEN_PROJECTBASEDIR=%EXEC_DIR%
|
||||
cd "%EXEC_DIR%"
|
||||
|
||||
:endDetectBaseDir
|
||||
|
||||
IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig
|
||||
|
||||
@setlocal EnableExtensions EnableDelayedExpansion
|
||||
for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
|
||||
@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
|
||||
|
||||
:endReadAdditionalConfig
|
||||
|
||||
SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
|
||||
set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
|
||||
set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
|
||||
|
||||
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
|
||||
|
||||
FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
|
||||
IF "%%A"=="wrapperUrl" SET DOWNLOAD_URL=%%B
|
||||
)
|
||||
|
||||
@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
|
||||
@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
|
||||
if exist %WRAPPER_JAR% (
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Found %WRAPPER_JAR%
|
||||
)
|
||||
) else (
|
||||
if not "%MVNW_REPOURL%" == "" (
|
||||
SET DOWNLOAD_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar"
|
||||
)
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Couldn't find %WRAPPER_JAR%, downloading it ...
|
||||
echo Downloading from: %DOWNLOAD_URL%
|
||||
)
|
||||
|
||||
powershell -Command "&{"^
|
||||
"$webclient = new-object System.Net.WebClient;"^
|
||||
"if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^
|
||||
"$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^
|
||||
"}"^
|
||||
"[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%DOWNLOAD_URL%', '%WRAPPER_JAR%')"^
|
||||
"}"
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Finished downloading %WRAPPER_JAR%
|
||||
)
|
||||
)
|
||||
@REM End of extension
|
||||
|
||||
@REM Provide a "standardized" way to retrieve the CLI args that will
|
||||
@REM work with both Windows and non-Windows executions.
|
||||
set MAVEN_CMD_LINE_ARGS=%*
|
||||
|
||||
%MAVEN_JAVA_EXE% ^
|
||||
%JVM_CONFIG_MAVEN_PROPS% ^
|
||||
%MAVEN_OPTS% ^
|
||||
%MAVEN_DEBUG_OPTS% ^
|
||||
-classpath %WRAPPER_JAR% ^
|
||||
"-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^
|
||||
%WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
|
||||
if ERRORLEVEL 1 goto error
|
||||
goto end
|
||||
|
||||
:error
|
||||
set ERROR_CODE=1
|
||||
|
||||
:end
|
||||
@endlocal & set ERROR_CODE=%ERROR_CODE%
|
||||
|
||||
if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost
|
||||
@REM check for post script, once with legacy .bat ending and once with .cmd ending
|
||||
if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat"
|
||||
if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd"
|
||||
:skipRcPost
|
||||
|
||||
@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
|
||||
if "%MAVEN_BATCH_PAUSE%"=="on" pause
|
||||
|
||||
if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE%
|
||||
|
||||
cmd /C exit /B %ERROR_CODE%
|
||||
@@ -1,98 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<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.boot</groupId>
|
||||
<artifactId>spring-boot-starter-parent</artifactId>
|
||||
<version>3.1.3</version>
|
||||
<relativePath/> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
|
||||
<groupId>org.springframework.ws</groupId>
|
||||
<artifactId>smoke-tests</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
|
||||
<name>smoke-tests</name>
|
||||
<description>smoke-tests</description>
|
||||
|
||||
<properties>
|
||||
<java.version>17</java.version>
|
||||
<spring-framework.version>6.0.14</spring-framework.version>
|
||||
<stagingRepositoryId>orgspringframework-springws</stagingRepositoryId>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.ws</groupId>
|
||||
<artifactId>spring-ws-core</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
<profiles>
|
||||
<profile>
|
||||
|
||||
<id>maven-central</id>
|
||||
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>s01.oss.sonatype.org</id>
|
||||
<url>
|
||||
https://s01.oss.sonatype.org/service/local/repositories/${stagingRepositoryId}/content/
|
||||
</url>
|
||||
</repository>
|
||||
</repositories>
|
||||
</profile>
|
||||
<profile>
|
||||
|
||||
<id>artifactory</id>
|
||||
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>spring-libs-snapshots</id>
|
||||
<url>
|
||||
https://repo.spring.io/libs-snapshot-local/
|
||||
</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-libs-milestone</id>
|
||||
<url>
|
||||
https://repo.spring.io/libs-milestone-local/
|
||||
</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-libs-release</id>
|
||||
<url>
|
||||
https://repo.spring.io/libs-release-local/
|
||||
</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-snapshot</id>
|
||||
<url>https://repo.spring.io/snapshot</url>
|
||||
<snapshots>
|
||||
<enabled>true</enabled>
|
||||
</snapshots>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-milestone</id>
|
||||
<url>https://repo.spring.io/milestone</url>
|
||||
</repository>
|
||||
<repository>
|
||||
<id>spring-release</id>
|
||||
<url>https://repo.spring.io/release</url>
|
||||
</repository>
|
||||
</repositories>
|
||||
</profile>
|
||||
</profiles>
|
||||
|
||||
|
||||
</project>
|
||||
@@ -1,24 +0,0 @@
|
||||
= Release Smoke Tests
|
||||
|
||||
== Maven Central
|
||||
|
||||
To run smoke tests against a Maven Central staging repository:
|
||||
|
||||
[source,shell]
|
||||
----
|
||||
$ mvnw -Pmaven-central -Dspring-ws.version=${projectVersion} -DstagingRepositoryId=${stagingRepositoryId}
|
||||
----
|
||||
|
||||
* `${projectVersion}`: e.g. `4.0.4`
|
||||
* `${stagingRepositoryId}`: e.g. `orgspringframework-2601`
|
||||
|
||||
== Artifactory
|
||||
|
||||
To run smoke tests against an Artifactory staging repository:
|
||||
|
||||
[source,shell]
|
||||
----
|
||||
$ mvnw -Partifactory -Dspring-ws.version=${projectVersion}
|
||||
----
|
||||
|
||||
* `${projectVersion}`: e.g. `4.0.4`
|
||||
@@ -1,15 +0,0 @@
|
||||
package org.springframework.ws.smoketests;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.ws.client.core.WebServiceTemplate;
|
||||
|
||||
/**
|
||||
* Smoke tests to bootstrap Spring module components to verify they are functional.
|
||||
*/
|
||||
class SmokeTestsApplicationTests {
|
||||
|
||||
@Test
|
||||
void createWebServiceTemplate() {
|
||||
WebServiceTemplate template = new WebServiceTemplate();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user