rdf4j logo Eclipse rdf4j: documentation


Developer Workflow and Project Management

In this document the Eclipse RDF4J project workflow and developer best practices are explained. It contains information on how to create branches, tag releases, manage pull requests, create and schedule issues, and so on. Some of this information is targeted specifically at the project lead(s), other information is relevant to every committer.

1. Semantic Versioning

RDF4J strives to apply Semantic Versioning principles to its development:

  1. We use a MAJOR.MINOR.PATCH versioning template.

  2. A PATCH release (2.1.5, 2.1.6, etc.) is a release that contains only bug fixes that are backwards compatible.

  3. A MINOR release (2.0, 2.1, 2.2, etc.) is a release that can contain improvements and new features but makes no backward-incompatible changes to existing functionality.

  4. A MAJOR release (1.0, 2.0, 3.0, etc) is a release that can contain changes to the public API that are not backward compatible.

It is currently not fully specified what the boundaries of the RDF4J public API are. Until this is resolved (see issue #619), we allow changes to public or protected methods/classes/interfaces in minor releases under the following conditions:

  1. any renamed interface is declared an extension of the old interface. The old interface is marked deprecated with Javadoc containing a reference to the new name;

  2. any renamed class is declared a superclass of the old class. The old class is marked deprecated with Javadoc containing a reference to the new name;

  3. any renamed member is added next to the old member name. The old member is declared deprecated with Javadoc containing a reference to the new name.

These conditions are to ensure that existing user code will continue to work when upgrading to the new release. If there is any doubt about a change being backwards-compatible, it can not be made part of a minor release.

For patch releases we never allow changes in the public API, unless the change is specifically to fix a bug that aligns the actual behavior of the code with the publicly documented behavior.

2. Workflow

RDF4J uses a git branching model where feature development takes place on branches from the master branch. This is where all development for the next (minor or major) release happens.

Every issue, no matter how small, gets its own branch while under development. Issue branch names are always prefixed with issues/, followed by the issue number in the GitHub issue tracker, followed by one or two dash-separated keywords for the issue.

For example: issues/#276-rdfxml-sax is the branch for a fix for GitHub issue #276, which has to do with RDF/XML and the SAX parser.

Once a feature/fix is complete, tested, and reviewed (via a Pull Request), it is merged into master, and the issue branch is closed.

3. Patch releases

Patch releases are created by cherry-picking desired bug fixes from the master branch into a release branch, and when complete, tagging this release branch with the version number before release deployment. Once release deployment is complete, the release branch is merged back into the master branch, and then deleted.

A patch release can be done in an ad-hoc fashion, without the need for a formal review. Plans to do a patch release are announced by the project lead on the rdf4j-dev@eclipse.org mailinglist, usually about a week in advance, with an open invitation for contributers to propose additional fixes to include.

3.1. Creating a release branch

A patch release uses its immediate predecessor release as its basis. This means we need to create a release branch not by simply branching from the current master branch, but by branching from a specific release tag. To create a patch release branch, follow these steps:

  1. Check out the tag of the previous release.

    E.g. if we’re preparing a release 2.1.6, the previous release is 2.1.5, so we do:

    git checkout 2.1.5
  2. Create a new release branch, named releases/<version>:

    git branch releases/2.1.6
  3. Fix maven version numbers in the release branch.

    We need to set the project version to 2.1.6-SNAPSHOT by using:

    mvn versions:set

    This will ask for the new version number. Enter 2.1.6-SNAPSHOT to indicate that this is the development branch for the upcoming 2.1.6 release.

    After this is done, execute

    mvn versions:commit

    which will remove backup files.

    Finally, commit the version number changes:

    git commit -s -a -m "release branch for 2.1.6"
  4. Push the newly created branch, as follows:

    git push -u origin releases/2.1.6

3.2. Cherry-picking fixes

Bug fixes are typically added to a patch release branch by cherry-picking the relevant commits from the master branch.

This works as follows:

  1. Check out the patch release branch.

  2. In the git commit history, identify the commit for the fix you wish to add to the release. You can usually easily find this by looking at the original Pull Request for the (normally the PR can be found by looking through the issue coments on GitHub). You’re looking for a message in the PR about the merge, usually at the end, that looks like this:

    jeenbroekstra merged commit 5d13554 into eclipse:master

    The commit number (5d13554) is what you’re after.

  3. Add this fix to the release branch by executing the following command:

    git cherry-pick -m 1 5d13554

    The -m 1 flag is necessary because this is a merge-commit, which has two parents: we need inform git which parent commit it needs to use as the base (we select 1, which is the master branch, to ensure that only changes introduced by this fix are included).

  4. Push your changes and update the patch release project board.

3.3. Tagging and finalizing the release

Once all fixes are applied to the release branch, and the build is stable (NB verify by executing mvn clean verify), we can tag and finalize the release:

  1. Set the maven pom version numbers.

    We need to set the project version to from 2.1.6-SNAPSHOT to 2.1.6 by using:

    mvn versions:set

    This will ask for the new version number. Enter 2.1.6 to indicate that this is the actual code for 2.1.6 release.

    After this is done, execute

    mvn versions:commit

    which will remove backup files.

    Finally, commit the changes and push:

    git commit -s -a -m "patch release 2.1.6"
    git push
  2. Tag the version and push the tag upstream:

    git tag 2.1.6
    git push -u origin 2.1.6

4. Release distribution deployment

RDF4J has two separate distributions:

  1. the SDK and onejar archives, downloadable via http://www.rdf4j.org/download .

  2. the Maven artifacts, available via The Central Repository.

4.1. Building and uploading Maven artifacts

We use the Eclipse RDF4J Hudson CI instance to build and deploy new releases to the Central Repository. To do this, simply log in to Hudson, and start the job named rdf4j-deploy-release-ossrh-central. The job will ask for the release tag as an input parameter, e.g. '2.1.6'.

This Hudson job will automatically check out the release tag, build the project, and upload all artifacts to OSS Sonatype. After successful upload, it will also automatically invoke synchronization with the Central Repository. Note that after successful completion, the artifacts may not be available on the Central Repository for several hours.

4.2. Building and uploading SDK and onejar

The SDK and onejar archives are hosted on https://www.eclipse.org/downloads/ . The archives need to be built locally, and uploaded manually, via secure FTP.

4.3. Building the SDK and onejar

  1. Check out the release tag

  2. Enter the core directory:

    cd core
  3. From the core directory, execute the following:

    mvn -Passembly clean package

Once this completes, the SDK and onejar can be found in core/assembly/target. Verify that the SDK is complete by inspecting its contents (in particular, check that javadoc is included).

4.4. Uploading the SDK and onejar

  1. SFTP to build.eclipse.org. You will need to provide your eclipse username and password.

  2. Go to remote directory /home/data/httpd/download.eclipse.org/rdf4j.

  3. Upload the SDK and onejar archives to this directory (NB we currently only distribute the SDK zip file, not the tar.gz file)

4.5. Closing the release branch

Once the release is complete, the project lead merges the release branch back into the master branch, and then deletes it.

On merge, usually conflicts will occur on all pom.xml files - this is due to version number updates in the release branch. These conflicts can be easily resolved by just selecting all pom files and indicating that the conflict should be resolved by just using the master ("mine") version.

Once the branch is merged, it needs to be deleted. Although this can of course be done from the command line, it is cumbersome, and we recommend using a decent Git client (like SourceTree) that can do this for you.

Note that, although the branch is deleted, the release tag is still in place, for future use of further patch release branches.

5. Minor and Major releases

The technical steps involved in creating a minor or major release are almost identical to those for creating a patch release. The main difference is that a release branch is usually not created until a few days before the planned release, and it is created directly from the master branch, not from the tag of the previous release. For this reason, it also does not involve cherry-picking fixes.

However, minor and major releases require a formal release review, and because this is the case, they need to be planned well in advance, and the project lead needs to manage what can go into each release, and prepare necessary documentation (both technical and legal) for review.

5.1. Release planning

We plan each release about 8 weeks in advance. At this stage, the final feature set is not etched in stone but a number of priority features/improvements is identified (via discussion on the mailinglist and/or via issue tracker comments and PRs) and scheduled. A first draft of a release plan is created by the project lead on the Eclipse RDF4J project site, and the necessary milestones are created in the RDF4J issue tracker. In addition, the next minor release planning board is updated.

5.2. Scheduling a release date

A release can only be done once its review is succesfully concluded. Eclipse release review are announced in regular cycles, and always complete on the first or third Wednesday of each month. For this reason, we schedule our releases to happen on a first or third Thursday.

5.3. Review planning and application

A release review runs for a week. Although mostly a formality, it does need some careful preparation and planning. It needs to be formally applied for, and this application in turn requires that several pieces of documentation are in order:

  1. The project’s IP log needs to be filed and approved by the Eclipse legal team;

    The IP log can be automatically generated and submitted to the legal team. Obtaining approval may require several days, so it’s good practice to submit this at least two weeks before the planned release date.

  2. The project’s review documentation, part of the application, needs to be in order.

Typical review documentation can be a simple reiteration of the most important new features, a link to the issue tracker/release notes and documentation, and a remark about compatibility (if applicable). Once the review documentation is up, a mail needs to be sent to technology-pmc@eclipse.org to ask for approval. Here’s an example of such a message, which was to get approval for the RDF4J 2.2 release:

Dear PMC members,

Can I get your approval for RDF4J release 2.2, scheduled for February 2.

Release review info: https://projects.eclipse.org/projects/technology.rdf4j/reviews/2.2-release-review

Issue tracking the release: https://bugs.eclipse.org/bugs/show_bug.cgi?id=510577

Kind regards,

Jeen Broekstra

When IP log approval and review approval have been given, the review can be scheduled. To do this, emo@eclipse.org needs to be notified. This can happen through the eclipse project governance page (accessible through the project site), which will show a link at the top of the page for the planned release.

For more detailed information about the release review process, see the Eclipse Project Handbook.

6. Further reading

Some generic sources of information about projects hosted by Eclipse: