You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 94 Next »

This document describes how to release Apache Kafka from trunk. 

It is a work in progress and should be refined by the Release Manager (RM) as they come across aspects of the release process not yet documented here.

NOTE: For the purpose of illustration, this document assumes that the version being released is 0.10.0.0 and the following development version will become 0.10.1.0.


Prerequisites

  • Prepare release plan in the wiki, notifying the community the overall plan and goals for the release (For example: Release Plan 0.10.0)
  • Vote on release plan: Release manager should start a vote in dev@kafka.apache.org, asking the community to approve the release plan. 

    To: dev@kafka.apache.org
    Subject: [VOTE] Release plan - Kafka 0.10.0
    
    We are starting the process to prepare for Kafka $release release. I have created release plan ($link) to cover the tasks under this release.
    
    If you have any JIRA in progress and would like to include it in this release, please follow the process to do so.
    
    Feel free to comment on the JIRA if you have any comments/suggestions.
    
    Thanks,
    $RM
    
    
  • Go over JIRA for the release and make sure that blockers are marked as blockers and non-blockers are non-blockers. This JIRA filter may be handy:

    project = KAFKA AND fixVersion = 0.10.0.0 AND resolution = Unresolved AND priority = blocker ORDER BY due ASC, priority DESC, created ASC
  • It is important that between the time that the release plan is voted to the time when the release branch is created, no experimental or potentially destabilizing work is checked into the trunk. While it is acceptable to introduce major changes, they must be thoroughly reviewed and have good test coverage to ensure that the release branch does not start of being unstable. If necessary the RM can discuss if certain issues should be fixed on the trunk in this time, and if so what is the gating criteria for accepting them.

  • RM must have gpg keys with the public key publicly available to validate the authenticity of the Apache Kafka release: If you haven't set up gpg key, set up one using 4096 bit RSA (http://www.apache.org/dev/release-signing.html). Make sure that your public key is uploaded to one of the public servers (http://www.apache.org/dev/release-signing.html#keyserver). Also, add your public key to https://github.com/apache/kafka-site/blob/asf-site/KEYS
     

Cut Branches

  • Make sure you are working with a clean repo (i.e. identical to upstream - no changes in progress). If needed clone a fresh copy
  • git checkout trunk
  • Check that current HEAD points to commit on which you want to base new  release branch. Checkout particular commit if not.
  • git branch 0.10.0
  • git push apache 0.10.0
  • Check that the branch was correctly propagated to Apache using the webui: https://git-wip-us.apache.org/repos/asf?p=kafka.git
  • Modify the version in trunk to bump to the next one "0.10.1.0-SNAPSHOT" in gradle.properties, tests/kafkatest/__init__.py and kafka-merge-pr.py. Commit and push to trunk in apache.
  • Create new Jenkins Build job that validates the new branch (Java 7 is enough)
  • Send email announcing the new branch:

    To: dev@kafka.apache.org
    Subject: New release branch 0.10.0
    
    Hello Kafka developers and friends,
    
    As promised, we now have a release branch for 0.10.0 release (with 0.10.0.0
    as the version).
    Trunk has been bumped to 0.10.1.0-SNAPSHOT.
    
    I'll be going over the JIRAs to move every non-blocker from this release to
    the next release.
    
    From this point, most changes should go to trunk.
    *Blockers (existing and new that we discover while testing the release)
    will be double-committed. *Please discuss with your reviewer whether your
    PR should go to trunk or to trunk+release so they can merge accordingly.
    
    *Please help us test the release! *
    
    Thanks!
    
    $RM
    

Create Release Artifacts

Create a release tag - because our release branch is still 0.10.0.0-SNAPSHOT but our release artifact needs to be 0.10.0.0, we'll make the change in a tag:

  • Modify the version in 0.10.0 branch to remove "-SNAPSHOT" in gradle.properties, tests/kafkatest/__init__.py and kafka-merge-pr.py. Commit locally, but don't push to Apache.
  • Prepare an RC tag:
    • git tag -a 0.10.0.0-rc0 (this will tag the version change commit, get the rc part to match the actual rc number)
  • Move the branch head back, so future commits will still have "-SNAPSHOT"

    • git reset --hard HEAD~1
  • Push the tag to Apache:
    • git push --tags

Prepare a workspace:

Prepare a public release staging area:

  • The easiest way is to sftp them over to home.apache.org/public_html using your apache id (in sftp, first create kafka-0.10.0.0-candidate1, then put -r localDir kafka-0.10.0.0-candidate1).

Check NOTICE and LICENSE files

  • Make sure the NOTICE file has the correct year

Prepare release notes

  • Go to JIRA, move all unresolved jiras with "Fix versions" of 0.9.0.0 to future releases.
  • Select roadmap from left panel, click on "release notes" next to the release version and prepare/format the html release notes. The html version shows up at the bottom of the page. Save the release notes as RELEAE_NOTES.html
  • Upload the release notes to home.apache.org

Now prepare the source and release (after making sure you have gpg keys to sign the artifacts):

  • make sure your java is on jdk 1.7 (On mac: export JAVA_HOME=$(/usr/libexec/java_home -v 1.7))

  • git archive --format tar.gz --prefix kafka-0.10.0.0-src/ -o ../kafka-0.10.0.0-src.tgz 0.10.0.0-rc3

 

  • Make sure you have Gradle installed
  • gradle
  • ./gradlew clean releaseTarGzAll
  • cp core/build/distributions/* ../
  • sign the artifacts:
    • for file in *.tgz; do gpg --armor --output $file.asc --detach-sig $file; done
      for file in *.tgz; do gpg --verify $file.asc $file; done
      for file in *.tgz; do gpg --print-md md5 $file > $file.md5; done
      for file in *.tgz; do gpg --print-md sha1 $file > $file.sha1; done
      for file in *.tgz; do gpg --print-md sha512 $file > $file.sha2; done

Prepare java and scala docs.

  • ./gradlew clean scaladoc

Upload all the binary artifacts, release notes, java and scala doc to your home.apache.org URL.

  • Go drop whatever staging repository may be in the maven repo: https://repository.apache.org/#stagingRepositories
  • Make sure you have your gpg keys (see Prerequisites section for specifics)
  • Set up ~/.gradle.properties like the following. Make sure that you can login to  https://repository.apache.org/ with your apache id/passwd. The value for signing.keyId can be found by running "gpg --list-secret-keys --fingerprint". The number after the / in the first line is your signing.keyId.

              mavenUrl=https://repository.apache.org/service/local/staging/deploy/maven2
              mavenUsername=your-apache-id
              mavenPassword=your-apache-passwd
              signing.keyId=your-gpgkeyId
              signing.password=your-gpg-passphrase
              signing.secretKeyRingFile=/Users/your-id/.gnupg/secring.gpg

  Website update process:

  For new releases:

  • Make sure the documentation (docs/documentation.html, docs/quickstart.html,docs/api.html) are all referring to the correct release and links.
  • Git clone https://git-wip-us.apache.org/repos/asf/kafka-site.git
  • checkout the branch asf-site
  • The releaseTarGzAll target should auto-generate the configuration docs for broker/producer/consumer in ./core/build/distributions/kafka_2.10-0.9.0.0-site-docs.tgz. Untar the file in 090/.
  • Copy release javadoc to newly 090/.
  • Update documentation.html to include the new documentation link (090/documentation.html).
  • Update protocol.html to include the new protocol guide link (090/protocol.html).
  • Update downloads.html to include the new download links from mirrors and change last release to use archive.
  • Mark the version as released in Kafka JIRA (from JIRA administration panel, select versions and scroll mouse towards the end of the line for the particular version. From the dropdown list, select release and set the date).

Voting:

  • Send out a voting email to users@kafka.apache.orgdev@kafka.apache.orgkafka-clients@googlegroups.com. In the email, include the git revision next to the git tag (since tag will be dropped when rolling out a new RC).

    To: dev@kafka.apache.org
    Subject: [VOTE] 0.10.0.0 RC0
     
    Hello Kafka users, developers and client-developers,
    
    This is the first candidate for release of Apache Kafka 0.10.0.0. This is a major release that includes: (1) New message format including timestamps (2) client interceptor API (3) Kafka Streams. Since this is a major release, we will give people more time to try it out and give feedback.
    
    Release notes for the 0.10.0.0 release:
    http://home.apache.org/~gwenshap/0.10.0.0-rc0/RELEASE_NOTES.HTML
    
    *** Please download, test and vote by Monday, March 28, 9am PT
    
    Kafka's KEYS file containing PGP keys we use to sign the release:
    http://kafka.apache.org/KEYS
    
    * Release artifacts to be voted upon (source and binary):
    http://home.apache.org/~gwenshap/0.10.0.0-rc0/
    
    * Maven artifacts to be voted upon:
    https://repository.apache.org/content/groups/staging/
    
    * scala-doc
    http://home.apache.org/~gwenshap/0.10.0.0-rc0/scaladoc
    
    * java-doc
    http://home.apache.org/~gwenshap/0.10.0.0-rc0/javadoc/
    
    * tag to be voted upon (off 0.10.0 branch) is the 0.10.0.0 tag:
    https://git-wip-us.apache.org/repos/asf?p=kafka.git;a=tag;h=72fd542633a95a8bd5bdc9fdca56042b643cb4b0
    
    * Documentation:
    http://kafka.apache.org/0100/documentation.html
    
    * Protocol:
    http://kafka.apache.org/0100/protocol.html
    
    /**************************************
    
    Thanks,
    
    Gwen


Verification for voting:

  • gpg --import KEYS (KEYS can be obtained from http://kafka.apache.org/KEYS)
  • gpg --verify foo-1.0.tar.gz.asc foo-1.0.tar.gz
  • Test at least quickstart and unit tests for all scala versions.

If need to roll a new RC

 After the vote passes:

  • Remember: at least 3 days, 3 +1 from PMC members (committers are not enough!) and no -1.
  • Merge the last version change / rc tag into the release branch
  • Update version on the branch to 0.10.0.1
  • Send a vote closing email:

    To: dev@kafka.apache.org
    Subject: [RESULTS] [VOTE] Release Kafka version 0.10.0.0
    
    This vote passes with 8 +1 votes (4 bindings) and no 0 or -1 votes.
    
    +1 votes
    PMC Members:
    * $Name
    * $Name 
    To: dev@kafka.apache.org
    Subject: [RESULTS] [VOTE] Release Kafka version 0.10.0.0
    
    This vote passes with 7 +1 votes (3 bindings) and no 0 or -1 votes.
    
    +1 votes
    PMC Members:
    * $Name
    * $Name 
    * $Name
    
    Committers:
    * $Name
    * $Name
    
    Community:
    * $Name
    * $Name
    
    0 votes
    * No votes
    
    -1 votes
    * No votes
    
    Vote thread:
    http://markmail.org/message/faioizetvcils2zo
    
    I'll continue in the release process and announce a release in the next few days.
    
    $RM
  • Upload all artifacts, release notes, and docs to https://dist.apache.org/repos/dist/release/kafka (an svn repo, using Apache committer id/passwd)
  • Go to https://repository.apache.org/#stagingRepositories, find the uploaded artifacts and release this (this will push to maven central)
  • Wait for about a day for the artifacts to show up in apache mirror and maven central.
  • Send out an announcement email. You will need to use your apache email address to send out the email (otherwise, it won't be delivered to announce@apache.org).
    • Log into people.apache.org with your apache id.
    • Include a paragraph in the announcement email like: "According to git shortlog <number_of_contributors> people contributed to this release: <contributors>" where:
      • number_of_contributors is determined via `git shortlog -sn --no-merges <previous_release_tag>..<current_release_tag> | wc -l` (eg `git shortlog -sn --no-merges 0.8.2.2..0.9.0.0 | wc -l`)
      • contributors is determined via: `git shortlog -sn --no-merges <previous_release_tag>..<current_release_tag> | cut -f2 | tr '\n' ',' | sed -e 's/,/, /g'` (eg `git shortlog -sn --no-merges 0.8.2.2..0.9.0.0 | cut -f2 | sort --ignore-case | tr '\n' ',' | sed -e 's/,/, /g'`)
    • cat mail.txt|mail -s "[ANNOUCE] ..."  announce@apache.orgusers@kafka.apache.orgdev@kafka.apache.orgkafka-clients@googlegroups.com
  • Add the release data to https://reporter.apache.org/addrelease.html?kafka (must be a Kafka PMC member)

 

  • No labels