Background

Since griffin's parent pom is apache, our release process is inherited from apache parent pom(https://svn.apache.org/viewvc/maven/pom/tags/apache-18/pom.xml?view=markup).

Apache release process is different from local release as it needs to do gpg check.

So you need to have created a PGP (or GPG) key pair, which will be used in signing the release artifacts. For more information on using the Maven GPG plugin, see this introduction from Sonatype and the Maven GPG Plugin usage page. You may also want to run gpg-agent in order to avoid being prompted multiple times for the GPG key passphrase when performing a release.

Preparations

  • Install git

    sudo apt-get update
    sudo apt-get install git -y
  • Install maven3

    sudo apt-add-repository ppa:andrei-pozolotin/maven3
    sudo apt-get update
    sudo apt-get install maven3 -y
    
    
    # sudo vi /etc/profile
    export M2_HOME=/usr/share/maven3
    export PATH=$PATH:$M2_HOME/bin
    
    source /etc/profile
  • Install gpg-agent

    sudo apt-get install gnupg-agent -y
    
    # vi ~/.bashrc
    if test -f $HOME/.gpg-agent-info && \
        kill -0 `cut -d: -f 2 $HOME/.gpg-agent-info` 2>/dev/null; then
        GPG_AGENT_INFO=`cat $HOME/.gpg-agent-info | cut -c 16-`
    else
        # No, gpg-agent not available; start gpg-agent
        eval `gpg-agent --daemon --no-grab --write-env-file $HOME/.gpg-agent-info`
    fi
    export GPG_TTY=`tty`
    export GPG_AGENT_INFO
    
    # exit and login again
  • Import gpg keys

    # import or generate your gpg key
    ## import
    gpg --import XXX.asc
    ## generate
    gpg --full-generate-key
    
    # trust the key
    gpg --edit-key XXX
    trust
    5
    y
    quit
  • Install jdk8

    sudo mkdir /apache && sudo chmod 777 /apache
    cd /apache
    wget --no-cookies --no-check-certificate --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.tar.gz -O jdk8-linux-x64.tar.gz
    tar -xvzf jdk8-linux-x64.tar.gz
    ln -s jdk1.8.0_131 jdk
    
    # sudo vi /etc/profile
    export JAVA_HOME=/apache/jdk
    export PATH=$JAVA_HOME/bin:$PATH
    
    source /etc/profile
    
    # sudo vi $M2_HOME/bin/mvn
    JAVA_HOME=/apache/jdk
  • Install svn

    sudo apt-get install subversion -y
    mkdir ~/svn

Update maven Settings.xml File to authenticate scm servers

<?xml version="1.0" encoding="UTF-8"?>
  <settings xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"
      xmlns="http://maven.apache.org/SETTINGS/1.0.0"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <servers>
	  <!-- To publish a snapshot of some part of Maven -->
      <server>
        <id>apache.snapshots.https</id>
        <username>USERNAME</username>
        <password>PASSWORD</password>
      </server>
	  <!-- To stage a release -->
      <server>
       <id>apache.staging.https</id>
       <username>USERNAME</username>
       <password>PASSWORD</password>
      </server>
	  <!-- To stage a release of some part of Maven -->
      <server>
        <id>apache.releases.https</id>
        <username>USERNAME</username>
        <password>PASSWORD</password>
      </server>


	  <!-- To stage a website of some part of Maven -->
      <server>
       <id>stagingSite</id>
       <!-- must match hard-coded repository identifier in site:stage-deploy -->
       <username>USERNAME</username>
       <filePermissions>664</filePermissions>
       <directoryPermissions>775</directoryPermissions>
      </server>
      <server>
       <id>gpg.passphrase</id>
       <passphrase>GPG_PASSWORD</passphrase>
      </server>
    </servers>
  </settings>

Release Repository Preparation

  • Pull repository

    mkdir ~/git && cd ~/git
    git clone https://github.com/apache/griffin.git
    cd griffin
    git remote add apache-git https://gitbox.apache.org/repos/asf/griffin.git
  • Compile the project

    mvn clean install

Update Change Log

  • Cleanup JIRA so the Fix Version in issues resolved since the last release includes this release version correctly.
  •  Update the CHANGELOG based on the Text release reports from JIRA.
  • Review and update README.md if needed.
  • Commit any changes back to git
  • Stage any Roadmap or Release landing pages on the site.

Create release branch

git checkout master
git pull
git checkout -b griffin-x.x.x-rcX

Check license

mvn -Papache-release clean apache-rat:check -e -DskipTests

Dry run release

version=x.x.x
tag=griffin-$version
mvn -Papache-release release:prepare -DautoVersionSubmodules=true -DdryRun=true -Dtag=$tag -DreleaseVersion=$version

Verify

compare pom.xml with pom.xml.tag files, the only differences should be version number.

check release.properties to make sure scm has right versions.

verify signatures.

Cleanup for release

mvn -Papache-release release:clean

Prepare for release

mvn -Papache-release -U clean release:prepare -DautoVersionSubmodules=true -Dtag=$tag -DreleaseVersion=$version

Perform the release

mvn -Papache-release -Darguments='-Dmaven.test.skip.exec=true' release:perform -Dgoals=deploy -DlocalRepoDirectory=. -DlocalCheckout=true -Dusername=[your_apache_id]

Verify nexus release artifacts

  1. Verify the staged artifacts in the nexus repo
  2. Close the nexus staging repo
    • https://repository.apache.org/index.html
    • Staging repositories (under Build Promotion) --> Name column --> org.apache.griffin
    • Click checkbox for the open staging repo (org.apache.streams-XXX) and press Close in the menu bar.

svn submit artifacts to  

source:

https://repository.apache.org/content/repositories/orgapachegriffin-XXXX/org/apache/griffin/griffin/griffin-x.x.x-incubating/

target:

https://dist.apache.org/repos/dist/dev/incubator/griffin/x.x.x-incubating/

Download the zip, pom and asc files from source, DO NOT include md5 or sha1 files.

Create sha512 checksum files for zip and pom files.

sha512sum griffin-x.x.x-incubating-source-release.zip > griffin-x.x.x-incubating-source-release.zip.sha512
sha512sum griffin-x.x.x-incubating.pom > griffin-x.x.x-incubating.pom.sha512

Edit a CHANGES.txt for release notes.

Commit to the target in the right version directory.

Vote in dev@griffin.incubator.apache.org

Hi all,

	This is a call for a vote on releasing Apache Griffin 0.1.5-incubating, release candidate 3. This is the first release of Griffin.
	Apache Griffin is data quality service for modern data system, it defines a standard process to define, 
	measure data quality for well-known dimensions. With Apache Griffin, users will be able to quickly define their data quality requirements and then get the result in near real time in systematical approach.
	 
	The source tarball, including signatures, digests, etc. can be found at:
	https://dist.apache.org/repos/dist/dev/incubator/griffin/0.1.5-incubating
	The tag to be voted upon is 0.1.5-incubating:
	https://gitbox.apache.org/repos/asf?p=griffin.git;a=shortlog;h=refs/tags/0.1.5-incubating
	The release hash is :
	https://gitbox.apache.org/repos/asf?p=griffin.git;a=commit;h=fb3c197ff801127a21838969be5392d4ed67c878
	The Nexus Staging URL:
	https://repository.apache.org/content/repositories/orgapachegriffin-1006
	Release artifacts are signed with the following key:
	753AD8D8DF507D7232A9BDBD9B403B9B1BFBCC23
	KEYS file available:
	https://dist.apache.org/repos/dist/dev/incubator/griffin/KEYS
	For information about the contents of this release, see:
	https://dist.apache.org/repos/dist/dev/incubator/griffin/0.1.5-incubating/CHANGES.txt

	Please vote on releasing this package as Apache Griffin 0.1.5-incubating

	The vote will be open for 72 hours.

	[ ] +1 Release this package as Apache Griffin 0.1.5-incubating
	[ ] +0 no opinion
	[ ] -1 Do not release this package because ...

Thanks,
William
On behalf of Apache Griffin PPMC

What if vote failed

git tag -d apache-griffin-<VERSION> # delete locally
git push apache-git --delete tagname # delete remote tag
git push apache-git :apache-griffin-<VERSION> # delete in the Apache git repo
git push apache-git --delete <branch_name>  # delete remote branch

 

What if vote succeed, then vote in general@incubator.apache.org

Hi all,
    The Apache Griffin community has voted on and approved a proposal to release Apache Griffin 0.1.5-rc3. 
    We now kindly request that the Incubator PMC members review and vote on this incubator release candidate.

    Apache Griffin is data quality service for modern data system, it defines a standard process to define, measure data quality for well-known dimensions. With Apache Griffin, users will be able to quickly define their data quality requirements and then get the result in near real time in systematical approach.
	
	
    Griffin vote thread
    https://lists.apache.org/thread.html/bb6d39a0cffc1265df5dc1db00d22101ba85357242ce1efd5fedb854@%3Cdev.griffin.apache.org%3E
    Griffin vote result thread
    https://lists.apache.org/thread.html/f7179ae14dd49bbbe23daf4e10b68b7a8662153d40ee03871febb1c4@%3Cdev.griffin.apache.org%3E
	
    The source tarball, including signatures, digests, etc. can be found at:
    https://dist.apache.org/repos/dist/dev/incubator/griffin/0.1.5-incubating
	
    The tag to be voted upon is 0.1.5-incubating:
    https://git-wip-us.apache.org/repos/asf?p=incubator-griffin.git;a=shortlog;h=refs/tags/0.1.5-incubating
	
    The release hash is :
    https://git-wip-us.apache.org/repos/asf?p=incubator-griffin.git;a=commit;h=87f71017dc4bd925e309a540ca5783cf4c59dfff
	
    The Nexus Staging URL:
    https://repository.apache.org/content/repositories/orgapachegriffin-1005
	
    Release artifacts are signed with the following key:
    753AD8D8DF507D7232A9BDBD9B403B9B1BFBCC23
	
    KEYS file available:
    https://dist.apache.org/repos/dist/dev/incubator/griffin/KEYS
	
    For information about the contents of this release, see:
    https://dist.apache.org/repos/dist/dev/incubator/griffin/0.1.5-incubating/CHANGES.txt
	
	
    Please download the release candidate and evaluate the necessary items including checking hashes, signatures, build from source, run and test.
    Please vote on releasing this package as Apache Griffin 0.1.5-incubating
    The vote will be open for 72 hours.
    [ ] +1 Release this package as Apache Griffin 0.1.5-incubating
    [ ] +0 no opinion
    [ ] -1 Do not release this package because ...
Thanks,
William
on behalf of Apache Griffin PPMC









If vote succeed, then merge into the origin branch, otherwise, rollback as above.

git checkout master
git merge griffin-0.1.5-incubating-rc3
#git rename branch
#git branch -m griffin-0.1.5-incubating-rc3 griffin-0.1.5-incubating
git push apache-git griffin-0.1.5-incubating
git push apache-git master
 

Login into https://repository.apache.org/ , then click Release. It should then propagate to Apache release maven repository and eventually mirrored to maven central.

Wait and check http://repo2.maven.org/maven2/org/apache/griffin

svn submit release artifacts to  

target:

https://dist.apache.org/repos/release/dev/incubator/griffin

Download links should be using the mirror pages under https://www.apache.org/dyn/closer.cgi/incubator/griffin

Update website and announce the new release.

http://griffin.incubator.apache.org/2017/07/25/release/

hi all,


The Apache Griffin (incubating) team is pleased to announce the release of Griffin 0.1.5-incubating.


Apache Griffin is data quality solution for modern data system, 
it defines a standard process to define, measure data quality for well-known dimensions. 


The release is available at:
https://www.apache.org/dyn/closer.cgi/incubator/griffin


Thanks,


The Apache Griffin (incubating) team




=====
*DISCLAIMER*
Apache Griffin is an effort undergoing incubation at the Apache Software Foundation (ASF), sponsored by the Apache Incubator.


Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects.


While incubation status is not necessarily a reflection of the completeness or stability of the code, it does indicate that the project has yet to be fully endorsed by the ASF.


 

 

  • No labels