Author: buildbot Date: Sat Dec 19 16:51:59 2015 New Revision: 975947 Log: Staging update by buildbot for slider
Modified: websites/staging/slider/trunk/content/ (props changed) websites/staging/slider/trunk/content/developing/releasing.html Propchange: websites/staging/slider/trunk/content/ ------------------------------------------------------------------------------ --- cms:source-revision (original) +++ cms:source-revision Sat Dec 19 16:51:59 2015 @@ -1 +1 @@ -1720549 +1720946 Modified: websites/staging/slider/trunk/content/developing/releasing.html ============================================================================== --- websites/staging/slider/trunk/content/developing/releasing.html (original) +++ websites/staging/slider/trunk/content/developing/releasing.html Sat Dec 19 16:51:59 2015 @@ -210,8 +210,13 @@ git graph.</li> </ol> <h3 id="before-you-begin">Before you begin<a class="headerlink" href="#before-you-begin" title="Permanent link">¶</a></h3> <p>Read the <a href="http://incubator.apache.org/guides/releasemanagement.html">ASF incubator release manual</a></p> +<p>Make sure that you are building with the JDK of the minimum supported version +for Slider. Code compiled with later major versions of Java don't work +on earlier versions. </p> +<p>Check <a href="https://builds.apache.org/job/Slider-develop/">the Jenkins builds</a> to +verify that the build is stable.</p> <p>Check out the latest version of the branch to be released, -run the tests. This should be done on a checked out +run the tests. You should release a checked out version of the code that is not the one you are developing on (ideally, a clean VM), to ensure that you aren't releasing a slightly modified version of your own, and that you haven't accidentally @@ -223,6 +228,13 @@ according to the instructions in <a href create HBase and Accumulo clusters in the YARN cluster.</p> <p><em>Make sure that the integration tests are passing (and not being skipped) before starting to make a release</em></p> +<p>A good test matrix is:</p> +<ul> +<li>Insecure, Secure</li> +<li>Linux, Windows</li> +<li>Java 7, Java 8</li> +</ul> +<p>A pair of VMs are sufficient to cover this.</p> <p>Make sure there are no uncommitted files in your local repo. </p> <p>If you are not building against a stable Hadoop release</p> <ol> @@ -236,27 +248,29 @@ starting to make a release</em></p> Slider release.</p> <p><em>5.</em> Check ASF headers dependencies</p> <p>Ensure the rat check is clean. This rejects files which lack ASF headers</p> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">clean</span> -<span class="n">mvn</span> <span class="n">apache</span><span class="o">-</span><span class="nb">rat</span><span class="p">:</span><span class="n">check</span> <span class="o">-</span><span class="n">Prat</span> -</pre></div> - - +<p><code>mvn clean +mvn apache-rat:check -Prat</code></p> +<p>(if you've got packages that aren't linked off the main POM, they don't get cleaned up; you'll need to <code>rm</code> those directories. +If you are using <code>fish</code>, then <code>rm -rf */target</code> should do it.)</p> <h3 id="checking-licenses">Checking licenses<a class="headerlink" href="#checking-licenses" title="Permanent link">¶</a></h3> <p>Maven can check that all dependent artifacts have valid licenses</p> <p>For modules which publish JARs (<code>slider-core</code> and <code>slider-funtest</code>), run the third party check for JARs. If you run this at the top level project it will do it for the relevant sub projects.</p> -<div class="codehilite"><pre> <span class="c"># in slider toplevel dir</span> - <span class="n">mvn</span> <span class="nb">license</span><span class="p">:</span><span class="n">add</span><span class="o">-</span><span class="n">third</span><span class="o">-</span><span class="n">party</span> <span class="o">-</span><span class="n">Dlicense</span><span class="p">.</span><span class="n">useMissingFile</span> -</pre></div> - - -<p>You also need to verify that the slider-assembly module is compliant</p> -<div class="codehilite"><pre><span class="c"># in slider-assembly</span> -<span class="n">mvn</span> <span class="nb">license</span><span class="p">:</span><span class="n">aggregate</span><span class="o">-</span><span class="n">add</span><span class="o">-</span><span class="n">third</span><span class="o">-</span><span class="n">party</span> <span class="o">-</span><span class="n">Dlicense</span><span class="p">.</span><span class="n">useMissingFile</span> -</pre></div> - - +<p>Do this after building everything</p> +<p>```</p> +<h1 id="in-slider-toplevel-dir">in slider toplevel dir<a class="headerlink" href="#in-slider-toplevel-dir" title="Permanent link">¶</a></h1> +<p>mvn license:add-third-party -Dlicense.useMissingFile +```</p> +<p>This will generate license files under each module in +<code>target/generated-sources/license/THIRD-PARTY.txt</code>. Inspect it and make sure +there are no GPL or LGPL dependencies which do not also have a license option +which is permitted by the ASF.</p> +<p>You also need to verify that the slider-assembly and slider-agent modules are compliant</p> +<p>```</p> +<h1 id="in-slider-assembly-and-slider-agent">in slider-assembly and slider-agent<a class="headerlink" href="#in-slider-assembly-and-slider-agent" title="Permanent link">¶</a></h1> +<p>mvn license:aggregate-add-third-party -Dlicense.useMissingFile +```</p> <p>This generates the metadata for licenses. Dependencies without a license are warned about. To fix this, make sure that the (generated or updated) file <code>src/license/THIRD-PARTY.properties</code> has an entry for every dependency without a license, declaring what their license is.</p> @@ -264,79 +278,57 @@ has an entry for every dependency withou <p>Verify your GPG key is provided to Apache. </p> <p>Apache verifies that distributions are correctly signed. Login to <a href="https://id.apache.org">https://id.apache.org</a> and verify the -fingerprint of GPG key used to sign above is provided. (<code>gpg --fingerprint</code>) -Upload your GPG public key only to <code>/home/$ASF_USER/.pgpkey</code></p> -<div class="codehilite"><pre><span class="n">scp</span> <span class="n">public</span><span class="o">-</span><span class="n">key</span><span class="p">.</span><span class="n">asc</span> <span class="n">people</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="p">:.</span><span class="n">pgpkey</span> -</pre></div> - - -<p><em>Tip</em>: if you are creating a new key, remember what password/passphrase you have +fingerprint of GPG key used to sign above is provided. (<code>gpg --fingerprint</code>)</p> +<p>If you have no GPG key, add your fingerprint to the relevant field.</p> +<p>If you are creating a new key, remember what password/passphrase you have given it. Then generate a revocation certificate and store it somewhere, so that you can revoke the published key.</p> -<h5 id="note-profiles">Note: Profiles<a class="headerlink" href="#note-profiles" title="Permanent link">¶</a></h5> +<p>A new key will not be trusted by anyone else. You should introduce to the +Apache web of trust by getting other developers to sign it. This can be done +in person, or perhaps over a video conference in which key details can be confirmed.</p> +<h5 id="note-selecting-hadoop-versions">Note: Selecting Hadoop versions<a class="headerlink" href="#note-selecting-hadoop-versions" title="Permanent link">¶</a></h5> <p>The slider POMs offer different profiles of Hadoop versions to build against. The instructions -below do not choose one. If a profile is needed, append it to all the maven commands.</p> -<p>e.g. <code>mvn clean install -Prelease-2.6</code></p> +below use the default. If a profile is needed, append it to all the maven commands.</p> +<p>e.g. <code>mvn clean install -Prelease-2.7</code></p> <h2 id="prepare">Prepare<a class="headerlink" href="#prepare" title="Permanent link">¶</a></h2> <h3 id="check-everything-in">Check everything in<a class="headerlink" href="#check-everything-in" title="Permanent link">¶</a></h3> <p>This and other other commands assume that <code>origin</code> maps to <code>https://git-wip-us.apache.org/repos/asf/incubator-slider.git</code>; you can check this with <code>git remote -v</code></p> <ul> -<li>Verify that there's nothing not yet checked in<div class="codehilite"><pre><span class="n">git</span> <span class="n">status</span> -</pre></div> - - -</li> +<li>Verify that there's nothing not yet checked in</li> </ul> +<p><code>git status</code></p> <p>Everything must be checked in at this point.</p> <ul> -<li>Sync up with the ASF repo. You do not want to release the wrong code.<div class="codehilite"><pre><span class="n">git</span> <span class="n">checkout</span> <span class="n">develop</span> -<span class="n">git</span> <span class="n">pull</span> <span class="n">origin</span> -<span class="n">git</span> <span class="n">push</span> <span class="n">origin</span> -</pre></div> - - -</li> +<li>Sync up with the ASF repo. You do not want to release the wrong code.</li> </ul> +<p><code>git checkout develop +git pull origin +git push origin</code></p> <h3 id="start-the-jira">Start the JIRA<a class="headerlink" href="#start-the-jira" title="Permanent link">¶</a></h3> <p>Create a JIRA for the release, estimate 12h</p> -<div class="codehilite"><pre><span class="n">export</span> <span class="n">SLIDER_RELEASE_JIRA</span><span class="p">=</span><span class="n">SLIDER</span><span class="o">-</span>544 -</pre></div> - - +<p><code>export SLIDER_RELEASE_JIRA=SLIDER-544</code></p> <p>This seems pessimistic, but there may be surprises.</p> <h3 id="choose-your-versions">Choose your versions<a class="headerlink" href="#choose-your-versions" title="Permanent link">¶</a></h3> -<p>Choose the version number for the release</p> +<p>Choose the version number for the release and its successor for the development branch</p> <p>Example:</p> -<div class="codehilite"><pre>0<span class="p">.</span>61<span class="p">.</span>0<span class="o">-</span><span class="n">incubating</span> -0<span class="p">.</span>62<span class="p">.</span>0<span class="o">-</span><span class="n">incubating</span><span class="o">-</span><span class="n">SNAPSHOT</span> - - -<span class="n">export</span> <span class="n">SLIDER_RELEASE</span><span class="p">=</span>0<span class="p">.</span>61<span class="p">.</span>0<span class="o">-</span><span class="n">incubating</span> -<span class="n">export</span> <span class="n">SLIDER_DEV</span><span class="p">=</span>0<span class="p">.</span>62<span class="p">.</span>0<span class="o">-</span><span class="n">incubating</span><span class="o">-</span><span class="n">SNAPSHOT</span> -</pre></div> - - +<p>``` +0.61.0-incubating +0.62.0-incubating-SNAPSHOT</p> +<p>export SLIDER_RELEASE=0.61.0-incubating +export SLIDER_DEV=0.62.0-incubating-SNAPSHOT +```</p> <h3 id="test-that-everything-works">Test that everything works<a class="headerlink" href="#test-that-everything-works" title="Permanent link">¶</a></h3> <p>Do a final test run to make sure nothing is broken</p> <p>In the <code>slider</code> directory, run:</p> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">clean</span> <span class="n">install</span> <span class="o">-</span><span class="n">DskipTests</span> -</pre></div> - - +<p><code>mvn clean install -DskipTests</code></p> <p>(Make sure the build isn't trying to pull down its JARs from the Apache Staging repo)</p> <p>Once everything is built- including <code>.tar</code> files, run the tests</p> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">test</span> -</pre></div> - - +<p><code>mvn test</code></p> <p>Then the integration tests</p> -<div class="codehilite"><pre>mvn integration-test -Dslider.conf.dir=<span class="cp">${</span><span class="n">your</span><span class="o">-</span><span class="n">config</span><span class="o">-</span><span class="nb">dir</span><span class="cp">}</span> -</pre></div> - - +<p><code>mvn integration-test -Dslider.conf.dir=${your-config-dir}</code></p> <p>This will run the functional tests as well as the <code>slider-core</code> tests.</p> <p>It is wise to reset any VMs here, and on live clusters kill all running jobs. This stops functional tests failing because the job doesn't get started before @@ -346,21 +338,18 @@ finalizing the release notes.</p> <h3 id="create-a-release-branch">Create a release branch<a class="headerlink" href="#create-a-release-branch" title="Permanent link">¶</a></h3> <p>Create or check out a release branch,</p> <p>Example of creation then push to the origin</p> -<div class="codehilite"><pre><span class="n">git</span> <span class="n">checkout</span> <span class="o">-</span><span class="n">b</span> <span class="n">branches</span><span class="o">/</span><span class="n">branch</span><span class="o">-</span>0<span class="p">.</span>6 -<span class="n">git</span> <span class="n">push</span> <span class="n">origin</span> <span class="n">branches</span><span class="o">/</span><span class="n">branch</span><span class="o">-</span>0<span class="p">.</span>6 -</pre></div> - - +<p><code>git checkout -b branches/branch-0.6 +git push origin branches/branch-0.6</code></p> <p>This branch is where all the release work will take place. That can include patching and cherry picking from the development branch.</p> <h3 id="update-the-version-numbers-on-the-main-branch">Update the version numbers on the main branch<a class="headerlink" href="#update-the-version-numbers-on-the-main-branch" title="Permanent link">¶</a></h3> <p>Get back to the develop branch and patch its versions</p> -<div class="codehilite"><pre><span class="n">git</span> <span class="n">checkout</span> <span class="n">develop</span> -<span class="n">mvn</span> <span class="n">versions</span><span class="p">:</span><span class="n">set</span> <span class="o">-</span><span class="n">DnewVersion</span><span class="p">=</span>$<span class="n">SLIDER_DEV</span> -<span class="n">git</span> <span class="n">commit</span> <span class="o">-</span><span class="n">a</span> <span class="o">-</span><span class="n">m</span> "$<span class="n">SLIDER_RELEASE_JIRA</span> <span class="n">updating</span> <span class="n">development</span> <span class="n">POMs</span> <span class="n">to</span> $<span class="n">SLIDER_DEV</span>" -<span class="n">git</span> <span class="n">push</span> <span class="n">origin</span> -</pre></div> - - +<p>``` +git checkout develop +mvn versions:set -DnewVersion=$SLIDER_DEV +git commit -a -m "$SLIDER_RELEASE_JIRA updating development POMs to $SLIDER_DEV"</p> +<p>git push origin +```</p> +<p>You may want to hold back from pushing things up if you are doing a dry run</p> <h1 id="automated-releases-via-maven">Automated releases via maven<a class="headerlink" href="#automated-releases-via-maven" title="Permanent link">¶</a></h1> <p>The Slider project uses Maven to automatically publish all the slider artifacts âsource and binaryâ to the ASF repositories</p> <p>Core sequence</p> @@ -417,11 +406,8 @@ anyway.</p> <h3 id="environment-variable-setup">Environment variable setup<a class="headerlink" href="#environment-variable-setup" title="Permanent link">¶</a></h3> <p>It's handy to set up an environment with the arguments needed for releases.</p> -<div class="codehilite"><pre><span class="n">export</span> <span class="n">RELARGS</span><span class="p">=</span>"<span class="o">-</span><span class="n">DskipTests</span> <span class="o">-</span><span class="n">DskipITs</span> <span class="o">-</span><span class="n">Papache</span><span class="o">-</span><span class="n">release</span>" -<span class="n">echo</span> $<span class="n">RELARGS</span> -</pre></div> - - +<p><code>export RELARGS="-DskipTests -DskipITs -Papache-release" +echo $RELARGS</code></p> <p>The profile <code>apache-release</code> is used to select a subset of the app packages, because the default builds of these weren't usable and had odd version numbers too.</p> @@ -434,65 +420,58 @@ so cannot actively share the branch with <h3 id="clone-the-repo">Clone the repo.<a class="headerlink" href="#clone-the-repo" title="Permanent link">¶</a></h3> <p>Don't release from your development dir; do it somewhere clean. Why so? Easier to clean up and guaranteed isolation.</p> <p>In a directory of your choice</p> -<div class="codehilite"><pre><span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">git</span><span class="o">-</span><span class="n">wip</span><span class="o">-</span><span class="n">us</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="o">/</span><span class="n">repos</span><span class="o">/</span><span class="n">asf</span><span class="o">/</span><span class="n">incubator</span><span class="o">-</span><span class="n">slider</span><span class="p">.</span><span class="n">git</span> <span class="n">slider</span><span class="o">-</span>$<span class="n">SLIDER_RELEASE</span> -<span class="n">cd</span> <span class="n">slider</span><span class="o">-</span>$<span class="n">SLIDER_RELEASE</span> -</pre></div> - - +<p><code>git clone https://git-wip-us.apache.org/repos/asf/incubator-slider.git slider-$SLIDER_RELEASE +cd slider-$SLIDER_RELEASE</code></p> <h3 id="check-out-the-branch-you-plan-to-release-on-tag-it">Check out the branch you plan to release on; tag it<a class="headerlink" href="#check-out-the-branch-you-plan-to-release-on-tag-it" title="Permanent link">¶</a></h3> <p>The tag is so that if things go wrong you know what you have to roll back to.</p> -<div class="codehilite"><pre><span class="n">cd</span> <span class="n">incubator</span><span class="o">-</span><span class="n">slider</span> -<span class="n">git</span> <span class="n">checkout</span> <span class="o">-</span><span class="n">t</span> <span class="n">origin</span><span class="o">/</span><span class="n">branches</span><span class="o">/</span><span class="n">branch</span><span class="o">-</span>0<span class="p">.</span>6 -</pre></div> - - +<p><code>git checkout -t origin/branches/branch-0.6</code></p> <p>In the new clone, tag the head of the branch you plan to to work from. You don't need to push the tag to the repo.</p> -<div class="codehilite"><pre><span class="n">git</span> <span class="n">tag</span> <span class="o">-</span><span class="n">a</span> <span class="n">tag_2015</span><span class="o">-</span>01<span class="o">-</span>27<span class="o">-</span><span class="n">prerelease</span><span class="o">-</span>0<span class="p">.</span>61<span class="p">.</span>0 <span class="o">-</span><span class="n">m</span> "<span class="n">prior</span> <span class="n">to</span> <span class="n">maven</span> <span class="n">release</span> <span class="n">process</span>" -</pre></div> - - -<h2 id="test-deploy-a-snapshot">Test Deploy a snapshot<a class="headerlink" href="#test-deploy-a-snapshot" title="Permanent link">¶</a></h2> -<p>This pushes up a <code>-SNAPSHOT</code> version to the ASF snapshot repo. -It doesn't change the POMs; it does verify that you have the basic upload settings, signing keys etc.</p> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">clean</span> <span class="n">deploy</span> $<span class="n">RELARGS</span> <span class="o">-</span><span class="n">Darguments</span><span class="p">=</span>"$<span class="n">RELARGS</span>" -</pre></div> - - -<p>Assuming that all the test and integration tests have already been successful on normal workspace, you can skip the tests</p> +<p><code>git tag -a tag_2015-12-18-$SLIDER_RELEASE -m "starting release of $SLIDER_RELEASE"</code></p> +<h3 id="clean-build-it">Clean build it<a class="headerlink" href="#clean-build-it" title="Permanent link">¶</a></h3> +<p>Maybe: purge your entire repository of slider artifacts</p> +<p><code>rm -rf ~/.m2/repository/org/apache/slider</code></p> +<h2 id="maven-release-plugin">Maven Release plugin<a class="headerlink" href="#maven-release-plugin" title="Permanent link">¶</a></h2> +<p>The maven release plugin tries to do everything: update versions, +tag repositories, push up artifacts.</p> +<h3 id="test-deploy-a-snapshot">Test Deploy a snapshot<a class="headerlink" href="#test-deploy-a-snapshot" title="Permanent link">¶</a></h3> +<p>Create the -SNAPSHOT artifacts</p> +<p><code>mvn clean install -DskipTests</code></p> +<p>Then push up a <code>-SNAPSHOT</code> version to the ASF snapshot repo. +This dry-run verifies that you have the basic upload settings, signing keys etc.</p> +<p><code>mvn clean deploy $RELARGS -Darguments="$RELARGS"</code></p> <p>After the upload has completed, the complete archives will be in the version-specific subdirectory of</p> -<div class="codehilite"><pre><span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">repository</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="o">/</span><span class="n">content</span><span class="o">/</span><span class="n">repositories</span><span class="o">/</span><span class="n">snapshots</span><span class="o">/</span><span class="n">org</span><span class="o">/</span><span class="n">apache</span><span class="o">/</span><span class="n">slider</span><span class="o">/</span><span class="n">slider</span><span class="o">-</span><span class="n">assembly</span><span class="o">/</span> -</pre></div> - - +<p><code>https://repository.apache.org/content/repositories/snapshots/org/apache/slider/slider-assembly/</code></p> +<p>(there may be older versions there from previous dry runs: look for the one with the date of your run on it)</p> <p>Download the uploaded <code>.tar.gz</code>, expand it and verify that it is complete. That includes</p> <ol> +<li>Download the associate <code>.asc</code> file with the PGP signature.</li> +<li>Validate the signature: <code>gpg --verify slider-assembly-*.asc</code></li> +<li>untar the assembly file: <code>tar -xz slider-assembly*.tar.gz</code></li> <li>Verify that the file <code>slider-agent.tar.gz</code> exists.</li> <li>Execute <code>bin/slider version</code></li> <li>Assuming you have an existing installation for testing, set <code>SLIDER_CONF_DIR</code> to the configuration directory, then -<code>slider start <INSTANCE></code> to start the relevant cluster instance. </li> +<code>./slider diagnostics --yarn --client --credentials --verbose</code> </li> </ol> -<h2 id="perform-a-dry-run-of-the-release">Perform a dry run of the release<a class="headerlink" href="#perform-a-dry-run-of-the-release" title="Permanent link">¶</a></h2> -<p>Perform a dry run. This will commit changes to your local branch.</p> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">release</span><span class="p">:</span><span class="n">prepare</span> <span class="o">-</span><span class="n">DdryRun</span><span class="p">=</span><span class="n">true</span> <span class="o">-</span><span class="n">DautoVersionSubmodules</span><span class="p">=</span><span class="n">true</span> <span class="o">-</span><span class="n">Darguments</span><span class="p">=</span>"$<span class="n">RELARGS</span>" -</pre></div> - - +<h3 id="perform-a-dry-run-of-the-release">Perform a dry run of the release<a class="headerlink" href="#perform-a-dry-run-of-the-release" title="Permanent link">¶</a></h3> +<p>Perform a dry run. This will prompt you for new versions âand commit changes to your local branch.</p> +<p><code>mvn release:prepare -DdryRun=true -DautoVersionSubmodules=true -Darguments="$RELARGS"</code></p> <ol> <li>This prompts for the version numbers for the slider version to release: use the <code>slider-0.61.0-incubating</code> or equivalent</li> -<li>Use the same (as recommanded) -go with them unless you have specific choices of +<li>go with them unless you have specific choices of versions. </li> <li>Look at the output to verify the versions are what you want.</li> -<li>Roll back to the commit tagged earlier</li> +<li>Roll back to the commit tagged earlier: <code>git reset --hard</code></li> </ol> <h2 id="perform-the-maven-release">Perform the Maven release<a class="headerlink" href="#perform-the-maven-release" title="Permanent link">¶</a></h2> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">release</span><span class="p">:</span><span class="n">clean</span> -<span class="n">mvn</span> <span class="n">release</span><span class="p">:</span><span class="n">prepare</span> <span class="o">-</span><span class="n">DautoVersionSubmodules</span><span class="p">=</span><span class="n">true</span> <span class="o">-</span><span class="n">Darguments</span><span class="p">=</span>"$<span class="n">RELARGS</span>" <span class="o">-</span><span class="n">Dresume</span><span class="p">=</span><span class="n">false</span> -<span class="n">mvn</span> <span class="n">release</span><span class="p">:</span><span class="n">perform</span> <span class="o">-</span><span class="n">Darguments</span><span class="p">=</span>"$<span class="n">RELARGS</span>" -</pre></div> - - +<p>``` +mvn release:clean</p> +<p>mvn -B release:prepare -DautoVersionSubmodules=true -Dtag=slider-$SLIDER_RELEASE \ + -DreleaseVersion=$SLIDER_RELEASE \ + -DdevelopmentVersion=$SLIDER_DEV \ + -Darguments="$RELARGS" -Dresume=false </p> +<p>mvn release:perform -Darguments="$RELARGS"</p> +<p>```</p> <ol> <li>The <code>release:prepare</code> command will trigger the local commit of changes to POMs, tagging this and pushing up the branch.</li> <li>Only skip those test runs if you have been running the tests in advance.</li> @@ -506,10 +485,7 @@ Consult <a href="http://stackoverflow.co After this phase (or when you cancel it), you'll need to roll back git,</p> <h3 id="tip-reverting-changes">Tip: reverting changes<a class="headerlink" href="#tip-reverting-changes" title="Permanent link">¶</a></h3> <p>Try</p> -<div class="codehilite"><pre><span class="n">mvn</span> <span class="n">release</span><span class="p">:</span><span class="n">rollback</span> -</pre></div> - - +<p><code>mvn release:rollback</code></p> <p>It <em>may</em> work. Then</p> <ol> <li>Via GUI/CLI Roll back the git branch to where it was before the release actions started @@ -518,11 +494,9 @@ changing things. That should be the revi <li>Delete any newly created <code>slider-XY-incubating</code> tag locally <em>and</em> remotely.</li> <li>Run <code>mvn clean</code></li> </ol> -<p>If you are in a specific release-only directory (as per the instructions):</p> -<div class="codehilite"><pre><span class="n">git</span> <span class="n">clean</span> <span class="o">-</span><span class="n">d</span> <span class="o">-</span><span class="n">f</span> <span class="o">-</span><span class="n">x</span> -</pre></div> - - +<p>If you are in a specific release-only directory (as recommended):</p> +<p><code>git clean -d -f -x +git reset --hard</code></p> <h3 id="tip-branching-instead-of-preparing">Tip: branching instead of preparing<a class="headerlink" href="#tip-branching-instead-of-preparing" title="Permanent link">¶</a></h3> <p>The <code>mvn release:branch</code> goal can be used instead of <code>mvn release:prepare</code>, which creates a branch explicitly for the release. We haven't used this yet.</p> @@ -530,15 +504,25 @@ which creates a branch explicitly for th <p>There's a small projects <a href="https://github.com/steveloughran/slider-dependency-check">slider-dependency-check</a> which verifies that slider artifacts can be downloaded from the public or staging repositories. Clone this project and read its instructions to verify that everything went up to the staging repo.</p> +<h3 id="tip-isolating-the-release-process-from-the-asf-repo">Tip: isolating the release process from the ASF repo<a class="headerlink" href="#tip-isolating-the-release-process-from-the-asf-repo" title="Permanent link">¶</a></h3> +<p>While trying to get the release out, the maven release plugin likes to commit things +to git, create tags and push them out. You can isolate your work from the ASF repository +by (temporarily) unhooking your release source tree from the ASF one.</p> +<p>You also need to isolate the repository settings in the build</p> +<p>Add these options to the build commands, using a URL to a repository to +which you do have access</p> +<p><code>-Pprivate-git-repo -Dgit.repo=https://github.com/steveloughran/incubator-slider.git</code></p> +<p>After creating a release to put up for a vote, you will need to push the +relevant (final) tag out to the ASF repository.</p> <h2 id="close-the-release-in-nexus">Close the release in Nexus<a class="headerlink" href="#close-the-release-in-nexus" title="Permanent link">¶</a></h2> <ol> -<li>log in to <a href="https://repository.apache.org/index.html">https://repository.apache.org/index.html</a> +<li>Log in to <a href="https://repository.apache.org/index.html">https://repository.apache.org/index.html</a> with your ASF username and LDAP password</li> -<li>go to <a href="https://repository.apache.org/index.html#stagingRepositories">Staging Repositories</a></li> -<li>find the latest slider repository in the list</li> -<li>select it; </li> +<li>Go to <a href="https://repository.apache.org/index.html#stagingRepositories">Staging Repositories</a></li> +<li>Find the latest slider repository in the list</li> +<li>Select it; </li> <li>Browse the content, verify the version number is what you want.</li> -<li>hit the "close" button. This will fail if it doesn't meet the ASF criteria</li> +<li>Hit the "close" button. This will fail if it doesn't meet the ASF criteria</li> <li>Wait for the close process to complete.</li> <li>Get the URL of the closed staging repository. This is needed for the next step âthe votes.</li> </ol> @@ -563,29 +547,24 @@ Slider project on JIRA.</p> <h2 id="get-the-votes-in">Get the Votes In<a class="headerlink" href="#get-the-votes-in" title="Permanent link">¶</a></h2> <h3 id="set-up-your-env-vars-for-email-templates">Set up your env vars for email templates<a class="headerlink" href="#set-up-your-env-vars-for-email-templates" title="Permanent link">¶</a></h3> <p>set up the environment with the git release tag, URL to the staging repository, and your ASF username:</p> -<div class="codehilite"><pre><span class="n">export</span> <span class="n">RELEASE_TAG</span><span class="p">=</span> -<span class="n">export</span> <span class="n">STAGING_REPO</span><span class="p">=</span> -<span class="n">export</span> <span class="n">ASF_USER</span><span class="p">=</span> -<span class="n">export</span> <span class="n">SOURCE_ZIP</span> -<span class="n">export</span> <span class="n">SOURCE_TAR_GZ</span> -</pre></div> - - +<p><code>export RELEASE_TAG= +export STAGING_REPO= +export ASF_USER= +export SOURCE_ZIP +export SOURCE_TAR_GZ</code></p> <p>example</p> -<div class="codehilite"><pre><span class="n">export</span> <span class="n">RELEASE_TAG</span><span class="p">=</span>64<span class="n">a8bac068e6801748fb973dbfb590bc62c60935</span> - -<span class="n">export</span> <span class="n">STAGING_REPO</span><span class="p">=</span><span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">repository</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="o">/</span><span class="n">content</span><span class="o">/</span><span class="n">repositories</span><span class="o">/</span><span class="n">orgapacheslider</span><span class="o">-</span>1003<span class="o">/</span> - -<span class="n">export</span> <span class="n">ASF_USER</span><span class="p">=</span><span class="n">stevel</span> - -<span class="n">export</span> <span class="n">SOURCE_ZIP</span><span class="p">=</span><span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">repository</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="o">/</span><span class="n">content</span><span class="o">/</span><span class="n">repositories</span><span class="o">/</span><span class="n">orgapacheslider</span><span class="o">-</span>1003<span class="o">/</span><span class="n">org</span><span class="o">/</span><span class="n">apache</span><span class="o">/</span><span class="n">slider</span><span class="o">/</span><span class="n">slider</span><span class="o">/</span>$<span class="n">SLIDER_RELEASE</span><span class="o">/</span><span class="n">slider</span><span class="o">-</span>$<span class="n">SLIDER_RELEASE</span><span class="o">-</span><span class="n">source</span><span class="o">-</span><span class="n">release</span>< span class="p">.</span><span class="n">tar</span><span class="p">.</span><span class="n">gz</span> - -<span class="n">export</span> <span class="n">SOURCE_TAR_GZ</span><span class="p">=</span><span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">repository</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="o">/</span><span class="n">content</span><span class="o">/</span><span class="n">repositories</span><span class="o">/</span><span class="n">orgapacheslider</span><span class="o">-</span>1003<span class="o">/</span><span class="n">org</span><span class="o">/</span><span class="n">apache</span><span class="o">/</span><span class="n">slider</span><span class="o">/</span><span class="n">slider</span><span class="o">/</span>$<span class="n">SLIDER_RELEASE</span><span class="o">/</span><span class="n">slider</span><span class="o">-</span>$<span class="n">SLIDER_RELEASE</span><span class="o">-</span><span class="n">source</span><span class="o">-</span><span class="n">release</spa n><span class="p">.</span><span class="n">zip</span> - -<span class="n">export</span> <span class="n">APACHE_VERSION_PAGE</span><span class="p">=(</span><span class="n">shorten</span> <span class="n">this</span> <span class="n">via</span> <span class="n">s</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="p">)</span><span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">issues</span><span class="p">.</span><span class="n">apache</span><span class="p">.</span><span class="n">org</span><span class="o">/</span><span class="n">jira</span><span class="o">/</span><span class="n">browse</span><span class="o">/</span><span class="n">SLIDER</span><span class="o">/</span><span class="n">fixforversion</span><span class="o">/</span>12327198 -</pre></div> - - +<p>``` +export RELEASE_TAG=64a8bac068e6801748fb973dbfb590bc62c60935 +export ASF_USER=stevel</p> +<p>export STAGING_REPO=https://repository.apache.org/content/repositories/orgapacheslider-1003 +curl --head $STAGING_REPO</p> +<p>export SOURCE_ZIP=$STAGING_REPO/org/apache/slider/slider/$SLIDER_RELEASE/slider-$SLIDER_RELEASE-source-release.tar.gz +echo $SOURCE_ZIP +curl --head $SOURCE_ZIP</p> +<p>export SOURCE_TAR_GZ=$STAGING_REPO/org/apache/slider/slider/$SLIDER_RELEASE/slider-$SLIDER_RELEASE-source-release.zip +echo $SOURCE_TAR_GZ</p> +<p>export APACHE_VERSION_PAGE=(shorten this via s.apache.org)https://issues.apache.org/jira/browse/SLIDER/fixforversion/12327198 +```</p> <h3 id="call-for-a-release-vote-on-the-devslider-list">Call for a release vote on the dev@slider list<a class="headerlink" href="#call-for-a-release-vote-on-the-devslider-list" title="Permanent link">¶</a></h3> <p>Call for a release VOTE to the dev mailing list (<code>d...@slider.incubator.apache.org</code>).</p> <p>To build the URLs, echo them then verify in your browser that they are present.</p> @@ -800,6 +779,12 @@ sprint âso wrap that up too.</p> <span class="n">git</span> <span class="n">pull</span> <span class="n">origin</span> <span class="n">mvn</span> <span class="n">clean</span> </pre></div> + + +<h2 id="manual-we-dont-trust-mvn-release-strategy">Manual "we don't trust <code>mvn release</code> strategy<a class="headerlink" href="#manual-we-dont-trust-mvn-release-strategy" title="Permanent link">¶</a></h2> +<p>``` +mvn versions:set -DnewVersion=$SLIDER_RELEASE</p> +<p>```</p> </div> <div id="footer">