From commits-return-33357-apmail-directory-commits-archive=directory.apache.org@directory.apache.org Fri Jan 13 13:33:27 2012 Return-Path: X-Original-To: apmail-directory-commits-archive@www.apache.org Delivered-To: apmail-directory-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9819A9570 for ; Fri, 13 Jan 2012 13:33:27 +0000 (UTC) Received: (qmail 77816 invoked by uid 500); 13 Jan 2012 13:33:27 -0000 Delivered-To: apmail-directory-commits-archive@directory.apache.org Received: (qmail 77748 invoked by uid 500); 13 Jan 2012 13:33:26 -0000 Mailing-List: contact commits-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@directory.apache.org Delivered-To: mailing list commits@directory.apache.org Received: (qmail 77741 invoked by uid 99); 13 Jan 2012 13:33:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Jan 2012 13:33:25 +0000 X-ASF-Spam-Status: No, hits=-1994.3 required=5.0 tests=ALL_TRUSTED,HTML_FONT_LOW_CONTRAST,HTML_MESSAGE,MIME_HTML_ONLY X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Jan 2012 13:33:21 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id q0DDX0Um000848 for ; Fri, 13 Jan 2012 13:33:00 GMT Date: Fri, 13 Jan 2012 08:33:00 -0500 (EST) From: confluence@apache.org To: commits@directory.apache.org Message-ID: <4864414.39348.1326461580101.JavaMail.confluence@thor> Subject: [CONF] Apache Directory Development > Releasing Studio MIME-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Auto-Submitted: auto-generated X-Virus-Checked: Checked by ClamAV on apache.org

Releasing Studio

Page edited by Pierre-Arnaud Marcelot


Changes (5)

=20 =20
=20 =20
Since we are using Nexus for = releases the release process is as follows (see also [http://www.apache.org= /dev/publishing-maven-artifacts.html#staging-maven]).

h3. 0. Verify Your Maven Settings

Several things need to be = correctly configured in your _'settings.xml'_ file located at _'= ;~/.m2/settings.xml'_.

Here's a sample file:
{noformat= }
<settings>
<servers>
<!-- To publish a s= napshot -->
<server>
<id>apache.snapshots.= https</id>
<username>[Your Apache ID]</username>= ;
<password>[Your Apache Password]</password>
= </server>
<!-- To stage a release -->
<serv= er>
<id>apache.releases.https</id>
<u= sername>[Your Apache ID]</username>
<password>[You= r Apache Password]</password>
</server>
</serv= ers>

<profiles>
<profile>
<i= d>apache-release</id>
<properties>
<= ;!-- To sign a release -->
<gpg.keyname>[Your Code Sig= ning Key ID]</gpg.keyname>
<gpg.passphrase>[Your Co= de Signing Key Password]</gpg.passphrase>
</properties&g= t;
</profile>
</profiles>
</settings> <= br>{noformat}

h3. 1. Test the Project
{= noformat}
...

Be aware that this phase= will ask you about the release version of Studio modules.
We use a release number s= cheme that combines a version number and the date of the release.:
=
An example of this release n= umber scheme is _'2.0.0.v20120111'_.
{noformat}
[Version using 'X.Y.Z' format].v[Date using &#= 39;YYYYMMDD' format]
{noformat}

An example of this release number scheme is _'2.0.0.v20120111'= ;_ (notice the '.v' string between the version and the date).
=
h3. 2. Deploy a Snapshot
= {noformat}
...

Full Content

Since we are using Nexus for releases the release process is as = follows (see also http://= www.apache.org/dev/publishing-maven-artifacts.html#staging-maven).

0. Verify You= r Maven Settings

Several things need to be correctly configured in your 'settings.xml= ' file located at '~/.m2/settings.xml'.

Here's a sample file:

<settings>
  <servers>
    <!-- To publish a snapshot -->
    <server>
      <id>apache.snapshots.https</id>
      <username>[Your Apache ID]</username>
      <password>[Your Apache Password]</password>
    </server>
    <!-- To stage a release -->
    <server>
      <id>apache.releases.https</id>
      <username>[Your Apache ID]</username>
      <password>[Your Apache Password]</password>
    </server>
  </servers>
 =20
  <profiles>
    <profile>
      <id>apache-release</id>
      <properties>
        <!-- To sign a release -->
        <gpg.keyname>[Your Code Signing Key ID]</gpg.keyname>
        <gpg.passphrase>[Your Code Signing Key Password]</gpg.pass=
phrase>
      </properties>
    </profile>
  </profiles>
</settings>

1. Test the Project
$ mvn release:prepare -DdryRun=3Dtrue

Be aware that this phase will ask you about the release version of Studi= o modules.
We use a release number scheme that combines a version number and the date = of the release:

[Version using 'X.Y.Z' format].v[Date using 'YYYYMMDD' format]

An example of this release number scheme is '2.0.0.v20120111' (= notice the '.v' string between the version and the date).

2. Deploy a Snapshot<= /h3>
$ mvn deploy

This is useful to verify your settings in ~/.m2/settings.xml (Nexus pass= word and GPG key)

3. Prepare the Rele= ase

First, clean the previous test release attempt with:

$ mvn release:clean

Next, edit the root 'pom.xml' file to comment the 'reposito= ry' and 'application' profiles, as we don't want these module= s (and their sub-modules) to be released in the Maven repository.

Also, edit the 'pom.xml' file of the 'Apache Directory Stud= io Libraries Plugins' module and remove the code related to skipping t= he deployment of 3rd party plugins:

  <build>
    <plugins>
       <!-- Skip deployment of 3rd party plugins. This causes problems w=
hen=20
            deploying snapshots because the 3rd party plugins don't have a=
=20
            snapshot version. -->
       <plugin>
         <artifactId>maven-deploy-plugin</artifactId>
         <configuration>
           <skip>true</skip>
        </configuration>
      </plugin>
    </plugins>
  </build>

Then, prepare the release with:

$ mvn release:prepare

This creates a tag here: http://svn.apache= .org/viewvc/directory/studio/tags/

4. Stage the Release<= /h3>
$ mvn release:perform

This deploys the release to a staging repository. Go to https://repository.apache.org/index.html#stagingRepo= sitories and close the staging repository.

5. Deploy the Site

$ cd target/checkout
$ mvn site-deploy

This creates and deploys the site via ssh to people.apache.org/www/direc= tory.apache.org/studio/gen-docs.

Edit the people.apache.org/www/directory.apache.org/studio/gen-docs/inde= x.html file and add the deployed site to the list.

6. Ge= nerate the distribution packages

Move into the 'application' sub-module:

$ cd application

Edit the 'pom.xml' files of this sub-modules and all other (sub= -)sub-modules to fix the parent version which still refers to the old versi= on number (it was not modified during the release process because the '= application' profile was commented):

$ text-editor-command pom.xml */pom.xml

Run the following command to generate all the distribution packages:

$ mvn clean install -Prelease

Now, you have all the distribution packages available at '../target/= release':

$ ls -l ../target/release

7. Publis= h Distribution Packages

$ cd ../target/release
$ scp apache-ldap-api-<version>-* people.apache.org:public_html/share=
d-<version>/

8. Vote

Start a 72h vote at the dev mailing list.

9. Release

If the vote succeeds Studio project can be released.

Go to https://repository.apache.o= rg/index.html#stagingRepositories and release the staging repository so= all artifacts are published to Maven central.

Move the distribution packages to people.apache.org/www/www.apache.org/d= ist/directory/studio.

For these examples we'll presume a release on trunk of studio. For relea= ses on the tags or branches change the svn checkout line to accomodate.

$ svn co https://svn.apache.org/repos/asf/directory/studio/trunk studi=
o
$ cd studio
$ mvn -Prelease -DdryRun=3Dtrue release:prepare    # Dry-run first. =20
...=20
... Make sure the change made by the release plugin is correct!
...
$ mvn release:clean      # Clean up the temporary files created by the dry-=
run.
$ mvn -Prelease release:prepare    # Copy to tags directory.
$ mvn -Prelease release:perform    # Upload the released artifacts to the m=
aven repository.
...=20
... Make sure the jars/poms and their signature files are properly deployed=
 to the m2-ibiblio-sync=20
... repository on people.apache.org before running the clean goal or else y=
ou cannot rollback the
... release.
...
$ mvn release:clean      # Clean up the temporary files.
3D""Outdated
3D""During the prepare goal's execution y= ou'll be asked a number of questions. Please pay close attention to each q= uestion instead of hitting return everytime. In particular there is a ques= tion about what you want to call the tag. If you do not specify the correc= t tag which should be the release number 1.3.0 in this case, maven will use= parent-1.3.0 instead without the parent- prefix. We don't want tha= t so pay attention. Look here if you have any questions regarding what rel= ease tags should be for the studio subproject:=20

http://svn.apache.org/viewvc/directory/stud= io/tags

These commands will build, tag, sign, and deploy studio artifacts and th= eir signature files to the repository. Check the following URLs during diff= erent stages of the process to see Maven at work: