Page History
...
Info | ||
---|---|---|
| ||
For lack of a better place at this time, here's some useful pages on Sonatype which detail the Sonatype Maven Release Process: |
Release Numbering Convention
major.minor.subminor (e.g. 1.6.0)
...
The one exception is that the Language Packs (dspace-api-lang
and dspace-xmlui-lang
) use the numbering convention major.minor.subminor.sequence-number (e.g. 1.6.0.0). This allows us to release new versions of the language packs more frequently than normal DSpace releases.
Prerequisites
Verify Release Privileges
To perform a release, you must have all of the following:
- Write access to the DSpace subversion repository hosted at http://scm.dspace.org/svn/repo; This requires an administrator to add you to the svn repository permissions via the TRAC user group.
- Write access to the org.dspace groupId in the snapshot and staging repositories hosted at oss.sonatype.org. If you don't already have this, you will need to:
- Sign up for a Sonatype JIRA account. This account will also serve as your login to the Sonatype OSS system
- Ask the previous release manager to request authorization for this account via the Sonatype JIRA system in the Open Source Project Repository Hosting project. Once Sonatype gives you the proper authorization, you should be able to login to the Sonatype OSS system using the same login/password you setup in Sonatype JIRA.
- The full details of signing up and getting access to Sonatype are also posted online here: Sonatype Maven Repository Usage Guide
- You must generate and publish your own personal Code Signing Key (required by Sonatype). Here are two sites that give hints on how to do that:
- Creating a Code Signing Key
- How to Generate PGP Signatures with Maven (required for all Sonatype releases)
- Make sure to publish your Key file to
hkp://pgp.mit.edu
, as this is the Key Server Sonatype uses for verification:Wiki Markup (e.g.) {{gpg --keyserver hkp://pgp.mit.edu --send-keys \[yourKeyID\]}}
- You can see if your key is already on that Key Server by visiting http://pgp.mit.edu and searching on your name
- Write access to projects.dspace.org (which is where the DSpace Projects website is hosted)
- Ask the previous release manager (or someone else with access) to be given access to this server.
- Include your proposed username
- Include a local SSH Public Key (which will be used for authentication).
Setting up a new person with proper access to projects.dspace.org
Here's notes from Mark Diggory on how to give someone else access to the OSUOSL server (projects.dspace.org):
- adduser -m <user-name>
- Add authorized key to
~/.ssh/authorizedkeys
(make sure permissions are correct on file) - Add user to /etc/groups
Code Block maven:x:4002:peterdietz,esm,mdiggory,tdonohue,ben,kim,apache
- Make sure
umask 002
is in the users~/.bash_profile
so maven permissions are written correctly.
Update Maven settings.xml
DSpace's root pom.xml already has the correct staging and snapshot repositories listed in the OSS parents distributionManagement section. In order to deploy, you will need to add your Sonatype OSS username and password to your local ~/.m2/settings.xml
file:
...
If you don't yet have a ~/.m2/settings.xml
file, you should create one, and copy the full contents above (obviously make sure to put in your username and password).
Avoid Using Maven 2.1.0 or 2.2.0
Make sure you're using a recent version of Maven. As of this writing, the latest was 2.2.1, and it worked fine. In particular, avoid version 2.2.0: it has a serious bug that affects deployments: MNG-4235. Maven 2.1.0 also is problematic, as it produces improper GPG signatures.
For more information see the Pre-Requisities section of theSonatype Maven Repository Usage Guide
Making a Snapshot Release (e.g. 'dspace-x.y.z-SNAPSHOT')
One Step Process
From a clean, up-to-date copy of trunk, run the following command:
...
The snapshot will be immediately available in the public Sonatype repository: http://oss.sonatype.org/content/groups/public
Making an Official Release (e.g. 'dspace-x.y.z' or 'dspace-x.y.z-rc1')
Note | ||
---|---|---|
| ||
These same steps are also covered in the Sonatype Maven Repository Usage Guide |
Release DSpace Language Packs (I18N)
If possible, you should release the DSpace Language Packs (i18n modules) before the main release. Oftentimes, it's best to release these one or two days prior to the DSpace release (that way they've already propagated out to the Maven repository).
...
- Checkout Language Pack Module:
svn co https://scm.dspace.org/svn/repo/modules/dspace-api-lang/trunk dspace-api-lang
- Do a Dry Run:
mvn release:prepare -DdryRun=true
- Tag and Increment Version:
mvn release:prepare -Dresume=false
- Make sure to assign a version number of the format: major.minor.subminor.sequence-number (e.g. 1.6.0.0, 1.6.0.1, etc for 1.6.0 releases of language packs)
- Deploy Artifacts to Staging:
mvn release:perform
- Verify and Release Staged Artifacts (see instructions at link)
Final Commits & Preparation
Double Check Language Packs' Version Ranges
Once the Language Packs are released, you may need to modify the DSpace Parent pom.xml (http://scm.dspace.org/svn/repo/dspace/trunk/pom.xml) to reference the new version of the Language Packs. This should be similar to the following:
...
Code Block |
---|
<dependency> <groupId>org.dspace</groupId> <artifactId>dspace-api-lang</artifactId> <version>[1.6.0.0,1.7.0.0)</version> </dependency> <dependency> <groupId>org.dspace</groupId> <artifactId>dspace-xmlui-lang</artifactId> <version>[1.6.0.0,1.7.0.0)</version> <type>war</type> </dependency> |
Ensure HTML & PDF versions of Documentation is Committed
Double check that the latest Wiki-based Documentation has been exported as HTML and PDF and committed to http://scm.dspace.org/svn/repo/dspace/trunk/dspace/docs/
Checkout Trunk or Branch to Release
Checkout a copy of the to-be-release version either from a branch or trunk.
Code Block |
---|
svn co https://scm.dspace.org/svn/repo/dspace/trunk dspace-release |
Do a Dry Run
This step is not required, but performs a useful sanity check without committing any changes. From your clean, up-to-date copy of trunk, run the following command:
...
Info | ||||
---|---|---|---|---|
| ||||
If you notice an issue or an error occurs, you can re-run the Dry Run using the following command:
|
Tag and Increment Version
This step will set the version declared in the project's pom.xml files, commit the changes to trunk, tag the release, and finally, check in another trunk change that increments the next development version (e.g. x.y.z-SNAPSHOT) in the pom.xml files.
...
Note | ||
---|---|---|
| ||
If backing out of this step is needed for any reason, the following will restore the subversion repository and your working copy to the state it was previously in:
|
Deploy Artifacts to Staging in Sonatype
This step will sign, checksum, and push all release artifacts (including javadocs and sources) to the Sonatype staging repository (http://oss.sonatype.org/). Run the following:
...
Info | ||
---|---|---|
| ||
If any errors or problems occur during the deploy, you can re-run |
Verify and Release Staged Artifacts in Sonatype
Note |
---|
For screenshots and more details on this step, visit the Sonatype Repository Usage Guide's section on Releasing your artifacts |
...
Info | ||
---|---|---|
| ||
If anything is incorrect, select the staged repository and select "Drop". After the problem is resolved, you can re-deploy the artifacts to staging and verify them again. To re-deploy an already-tagged release: |
Create the Distribution Zips for SourceForge
Wiki Markup |
---|
The previous actions will have checked out the release tag into the target directory under {{\[dspace-src\]/target/checkout}}. Navigate to that directory and execute the creation of the distributions using the following command. This will create two zip, bzip and gzipped files in the target directory. One set of files is the "binary" release, and the other set is the source release. |
...
Code Block |
---|
localhost$ cd target/checkout localhost$ mvn package -Pdistributions [INFO] Scanning for projects... [INFO] ---------------------------------------------------------------------------- [INFO] Building DSpace Parent Project [INFO] task-segment: [package] [INFO] ---------------------------------------------------------------------------- [INFO] [site:attach-descriptor] [INFO] [assembly:single -(execution. default-)] [INFO] Building zip: .../target/dspace-1.5.0-beta1-release.zip [INFO] Building tar: .../target/dspace-1.5.0-beta1-release.tar.gz [INFO] Building tar: .../target/dspace-1.5.0-beta1-release.tar.bz2 [INFO] Building zip: .../target/dspace-1.5.0-beta1-src-release.zip [INFO] Building tar: .../target/dspace-1.5.0-beta1-src-release.tar.gz [INFO] Building tar: .../target/dspace-1.5.0-beta1-src-release.tar.bz2 [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ |
Upload to SourceForge
Upload both the source and binary releases to Sourceforge.net. You can either upload them via the web interface, or copy them over via scp
or other command line tools. If you want to copy the files from command line, follow the directions found here: http://apps.sourceforge.net/trac/sourceforge/wiki/File%20management%20service
...
Code Block |
---|
scp <files> <username>,dspace@frs.sourceforge.net:"/home/frs/project/d/ds/dspace/DSpace\\ Release\\ Candidate/1.6.0-rc2/" |
After the Release is Finished
Warning | ||
---|---|---|
| ||
You must wait for all the packages to be available at http://repo2.maven.org/maven2/org/dspace/ before you announce the release. Until the DSpace packages are available in the Maven repository, no one else will be able to build DSpace using Maven. |
- Add the new contributors to the list: DSpaceContributors
- Coordinate Announcements with DuraSpace Staff:
- Announcement on dspace.org, duraspace.org, twitter
- Plus if new stable version, ask dspace.org admins to upload latest documentation
- Announce on mailing lists
- Link announcement on Home of Wiki, change any version numbers on that page.
- Ensure that the Latest Release page on dspace.org is updated.
- Add group corresponding to the version to the JIRA system (if not already there)
- Update Wiki pages, particularly these pages which refer to the Current and Next releases:
- Create a new branch in SVN for any upcoming sub-minor releases (if necessary)
Possible Errors you may Encounter
"Could not find model file" error (with language packs)
If you encounter one of these errors when building/packaging DSpace:
...