Remote path '/var/www/domains/springframework.org/static/htdocs' is no
longer hard-coded in docs/build.gradle, because (a) it will be needed
in two separate locations as schema uploads are developed, and (b) this
value should be easily editable during local testing.
:docs:uploadArchives symlink creation now checks to ensure that
any existing wildcard (e.g., 2.0.x) or 'latest-ga' symlinks do
not point to targets with greater lexical value than the version
being published. If so, the symlink will not be overwritten.
EXAMPLE
Given an existing docs/ directory listing as follows:
1.0.3.RELEASE
1.0.x -> 1.0.3.RELEASE
2.0.0.BUILD-SNAPSHOT
2.0.0.RC1
2.0.x -> 2.0.0.RC1
latest-ga -> 1.0.3.RELEASE
Upon publishing 1.0.4.RELEASE, the directory listing will update as
follows (asterisk indicates added / changed entries):
1.0.3.RELEASE
* 1.0.4.RELEASE
* 1.0.x -> 1.0.4.RELEASE
2.0.0.BUILD-SNAPSHOT
2.0.0.RC1
2.0.x -> 2.0.0.RC1
* latest-ga -> 1.0.4.RELEASE
This functionality worked as described prior to this change.
However, it would break down in the following scenario. Imagine the
existing directory listing had been as below, following the release
of Spring Integration 2.0.0.RELEASE:
1.0.3.RELEASE
1.0.x -> 1.0.3.RELEASE
2.0.0.BUILD-SNAPSHOT
2.0.0.RC1
2.0.0.RELEASE
2.0.x -> 2.0.0.RELEASE
latest-ga -> 2.0.0.RELEASE
Note that latest-ga points to 2.0.0.RELEASE. Prior to the changes
in this commit, if a new GA on the 1.0.x line were to be published
the latest-ga symlink would have been incorrectly updated:
1.0.3.RELEASE
* 1.0.4.RELEASE
* 1.0.x -> 1.0.4.RELEASE
2.0.0.BUILD-SNAPSHOT
2.0.0.RC1
2.0.0.RELEASE
2.0.x -> 2.0.0.RELEASE
! latest-ga -> 1.0.4.RELEASE
! indicates the mistake. We want latest-ga to point to the latest GA
release at all times. This now happens, such that the directory
listing would be updated as follows:
1.0.3.RELEASE
* 1.0.4.RELEASE
* 1.0.x -> 1.0.4.RELEASE
2.0.0.BUILD-SNAPSHOT
2.0.0.RC1
2.0.0.RELEASE
2.0.x -> 2.0.0.RELEASE
latest-ga -> 2.0.0.RELEASE
Note that 'latest-ga' remains unchanged.
This same logic applies when updating wildcard links. In the rare
case that a 1.0.4.RELEASE were published *after* a 1.0.5.RELEASE,
the wildcard symlink will not be updated. It will remain pointing
to 1.0.5.RELEASE.
.gradle scripts once in gradle/ dir now live in shared buildSrc/ dir.
Some hard-coding of Spring Integration specifics still remain and will
be removed shortly.
Previous to this change, symlinks at
http://static.springsource.org/spring-integration/docs had to be
maintained by hand. The build now automatically updates:
* 'Wildcard' symlinks (e.g.: 2.0.x -> 2.0.0.RC1) if the release type
is anything other than SNAPSHOT.
* 'Latest GA' symlink (e.g.: latest-ga -> 1.0.3.RELEASE) if the release
type is RELEASE.
Also, deletion of the docs zip archive is now consolidated into the
same 'sshexec' command as the unzipping itself. Unzipping is now
done with -q (quiet) to cut down on output noise.
The spring-integration/docs/ directory on static.springframework.org
has sticky group-write permissions. unzip is now invoked with the '-K'
flag to ensure that newly created directories respect these permissions.
This is important to ensure that different (ssh) users can release the
project without running into permissions errors. Without -K, the unzip
command will preserve whatever permissions were present on the files and
directories at the time of archiving, and this usually means that
group-write is off.
Of course, all this assumes that users doing releases are part of the same
group - 'springorg' in this case.
Prior to this change, a graphical Ivy-branded authentication dialog was
appearing when attepmting to scp the docs zip file to
static.springframework.org. This was because the 'keyFile' property
of the uploadArchives task was not being set. It is being set correctly
now, based on the value of the 'sshPrivateKey' project property that
must be set in gradle.properties. This value has been set on the
build server's gradle.properties file, such that the INT-NIGHTLY build
can succeed in pushing docs during the build.
Complete:
--------
- src/* documentation resources moved to 'docs' subproject
- docbook sources upgraded to Docbook 5
- formatted all docbook sources to strip tab characters and
eliminate trailing whitespace
- all projects compile and test successfully
- all artifacts upload successfully to s3, static.sf.org, etc.
Remaining:
---------
- documentation L&F needs work. CSS, images, and highlighting aren't
hooked up properly
- spring-integration-jdbc codegen bits in Maven POM need to be
transcribed into gradle
- dependencies that were optional or provided scope in maven are
currently 'compile' scope in Gradle. Need to figure out support
in Gradle to fix this.
- run through Eclipse classpath and project generation scenarios
- delete all Maven artifacts