From Wikitech
Jump to navigation Jump to search

Refinery-source is the JVM software on the Analytics Cluster using spark or hive UDFs. The source code is in the analytics/refinery/source.

How to deploy with Jenkins (and related steps)

Before starting, please check:

  • Check the latest refinery-source deployed version. This can be done in various ways on the git repository, for instance:
  • The Refinery source commit list and make sure that the has been updated with the latest version and possibly that [maven-release-plugin] has committed the related version bump changes (the last step is optional, it could be triggered manually following the instruction below).
  • Make sure you are logged in to Jenkins to see the pages linked in the steps below.

Have you read the instructions reported above? If so, please keep going, otherwise please read them!

Deploy procedure:

  1. Update the file at the root of the repository with changes that are going to be deployed - commit and merge this change.
  2. Release a new version of refinery-source jars to Maven:
    • Visit and make sure that:
      • Release Version should be the version number you wish to deploy
      • Development version should be the next iteration of development version, usually Release Version + 1 with -SNAPSHOT at the end
      • Example: Release 0.0.40 - Development 0.0.41-SNAPSHOT
      • If the versions are not the ones that you expect, you can refresh them with This is known to refresh the values that you'll see in the next step, but usually they should be pre-filled.
    • Check the "Specify custom SCM tag" checkbox
    • Change refinery-x.y.z to vx.y.z in the "SCM tag" input text-box and update the number. Example: refinery-0.0.40 is bad, v0.0.40 is good
    • Hit Schedule Maven Release Build. This will build all the jars and deploy them to Archiva, and once done send a job success email to Analytics-alerts. You can follow the job at that address:, in the bottom-left Build History panel (In case the last job fails, it will have a red dot before its build number - see below)
  3. Now we need to update the symlinks to the latest refinery-source jars in the refinery repository. This can also be done via Jenkins, by going to, and supplying the version number of the latest jars released, without the v prefix. Example: v0.0.40 is bad, 0.0.40 is good. Then hit Build. This will make a commit to refinery and send an email to Analytics-alerts on success.
  4. There are most chances that, having deployed some new/changed java/scala code, you wish to apply it in refinery oozie job(s). You then need to

If the maven release job failed (step 2)

First find why looking at job logs, and then skip the version number you were currently deploying

    • Update the changelog,md with the skipped version info
    • Deploy again!


Changing the archiva-ci password

Archiva expires user passwords periodically (every 90 days?). This means we need to update the archiva-ci user's password in Archiva, and also in the Jenkins stored credential.

Log into as the admin user (the password is in the ops pwstore). Go to 'Manage', click on the edit (pencil) button for the archiva-ci and change the password.

Then, log into jenkins and go to the archiva-ci credentials page. Click on the 'Update' link, then click on Change Password, and set the password to the same one you set in Archiva.

How to deploy from the CLI

  • Update the file at the root of the repository whith changes that are going to be deployed.
  • Prepare deployment (change pom.xml files, push to git):
mvn release:prepare
  • Check everything looks Ok:
  • Actually deploy (jar generation and uploads to archiva)
mvn release:perform

Please see the refinery page to deploy the jars and oozie code.