Project

General

Profile

Build Managers HowTo

Efficiently upgrading AF3 sources from version a.b.c to d.e.f

Upgrading AF3 (and TK2 version) involves changing about 400 places (plugin versions, plugin dependencies, feature dependencies, product files, about dialog, ...).
This procedure ensures that this can be done manually, but efficiently by using the Eclipse multi-file search and replace function.

This procedure was tested on Feb 3rd, 2014 without any problems both in the local and Jenkins build.
See enumeration point 7 for possible pitfalls.

1. Make sure You have all the build related projects in your workspace, e.g. for continuous build and manual release build,

  • org.fortiss.kernel.latest.build
  • org.fortiss.kernel.latest.feature
  • org.fortiss.kernel.latest.p2site
  • org.fortiss.af3.phoenix.latest.build
  • org.fortiss.af3.phoenix.latest.feature
  • org.fortiss.af3.phoenix.latest.p2site
  • org.fortiss.af3.phoenix.product.release.build
  • org.fortiss.af3.phoenix.product.release.feature
  • org.fortiss.af3.phoenix.product.release.product

2. Execute an Eclipse File Search with the following settings (enter UI field values without the quotes!)

  • Containing text = "a.b.c"
  • File name patterns = "*.product, MANIFEST.MF, category.xml, feature.xml, pom.xml, plugin.xml"
  • No other search option active.
  • Scope = "Workspace" (unless You want to run the replace incrementally, then use "Selected Projects")

3. You may want to inspect the results of this search before launching the replace action.
4. Execute the File Search again, but use the wizard's "Replace ..." button instead of the "Search" button.
5. Add the new version number into the upcoming dialog and hit "OK":

  • Replace: "a.b.c"
  • With: "d.e.f"

6. This should update every AF3 plugin, fragment, feature and product version to the new version.
7. However, if the immediate local build shows any compile errors, chances are that one of the following two things happened:

  • A newly introduced plugin was not correctly versioned and therefore was not hit by the search. Correct this problem now, so the next version upgrade will work smoothly.
  • The search accidentally changed the required version of some non-AF3 plugin (currently very unlikely since Eclipse is 3.8.+, while AF3 is 2.5.+). Correct this before checking in.

8. Update all the Jenkins projects to use e.f.g instead of a.b.c (continuous & nightly, AF3 & kernel)
9. Run continuous and nightly builds and product builds to see if anything fails on Jenkins.

Jenkins security: use mask password to avoid plaintext output of passwords

If a Jenkins build script needs a password, e.g. in order to perform an SVN tag command after a successful build, you MUST use the "mask password plugin" to avoid having the password printed in the build log.
See the "test-mask-password" test build here on how this works: https://jenkins.fortiss.org:8080/job/test-mask-password/
Note that anyone who can change the job configuration can also recover the password, so MAKE sure you set the access rights correctly.
And never make the IT to include someone in the hudson_admins group, who does not belong there.
You have been warned !