Subversion Revision Graph

This past summer, via my role as project owner for the Subclipse project, I decided to participate as a mentor in the Google Summer of Code program.  Summer of Code is a great way to bring some visibility to your project as well as build relationships with other open source developers.  One of the first things you have to do when participating in Summer of Code as a mentor organization is to come up with some ideas for projects that students can work on for the summer.  It needs to be something interesting enough to attract talented students and at the same time it ought to be something where a measurable amount of work can be accomplished in just one summer.  I came up with a number of ideas, but the one I knew someone would go after, and the one I hoped would get done, was to add a revision graph feature.

One of the top requests I hear from new Subversion users is the desire for a good revision graph feature.  Unfortunately the way that Subversion stores information in its repository is not conducive to providing a feature like this.  Specifically, Subversion does not currently track “copy-to” information.  It can tell you the history of a given item and trace that history back through all of the places it was “copied-from”, but for any given path/revision pair it cannot tell you if it has been copied to another location.  This is an essential feature to create a proper revision graph, so in order to draw a decent graph, you pretty much need to have the entire history of the repository available so that you can construct the “copy-to” information yourself.  Performance would be terrible if you had to get this history every time, so a good local cache of the information is essential.  This is a fairly challenging engineering task and therefore was one that the existing Subclipse team was unlikely to ever find the time to do.  At the same time, it was a great task for a motivated student.  Combined with the ability to visualize the information in cool ways via the rich graphical library that Eclipse provides, I knew we would attract some interest.

We were fortunate enough to attract a great student, Alberto Gimeno.  He dove right into the task when the Summer of Code program started and did a great job delivering the feature.  I was hoping we would come out of this with some interesting code that someone else might want to pick up and finish, but Alberto was able to drive this feature to a point that it was nearly ready to ship when the summer ended.  We have just spent a few months adding some Eclipse-polish to it and integrating it into Subclipse.  Today we release it, and this is what a simple graph looks like:

Notice that the graph is capable of showing merge information when used with Subversion 1.5.  It also contains a number of nice features made available via the Eclipse Graphical Editing Framework.  Namely, the ability to zoom in/out, export to an image file as well as the ability to navigate a large graph via the Outline view.

This feature will be included in an upcoming release of the CollabNet Desktop – Eclipse Edition.  You can get it today via the “dev-builds” update site for the CollabNet Desktop.  Download information for the CollabNet Desktop can be found at the project home here.

Additional details on the revision graph feature can be found at the Subclipse site.

I would like to close by once again thanking Alberto for the work he did on this feature.  I look forward to his continued involvement in this feature and the Subclipse project.  I would also thank Google for running Summer of Code and including Subclipse in the program for 2008.

Mark Phippard

Engineering manager for several teams at CollabNet, including CloudForge, Subversion, Subversion Edge, Git and our Desktops and Integrations. Project owner for the Subclipse project, which provides Subversion support in Eclipse. Also a full committer for the Subversion project. Product owner for GitEye, Subversion Edge and the CollabNet Desktops and Integrations.

Posted in Subversion
4 comments on “Subversion Revision Graph
  1. Manu says:

    If you use Trac, you can also check out the RevtreePlugin:

  2. We actually tried to take some of the UI ideas for the graph from that plug-in. But we could not find any public Trac servers that use it so it was hard to see what it looks like on real data. If you know if any public servers (open-source projects) that use that plug-in, I’d love to get a URL.
    It is kind of disappointing that the trac-hacks site itself does not use it.

  3. In few months you will see the light says:

    The cache problem is a children play. It could be resolved very easyly. In example, while I’ve written this message I’ve found one solution for this problem.
    The main questions around Subversion should not be related with performace issues but functionality.
    The revison graph integrated with Subclipse maybe is a very good job, but not a very great idea.
    Similar graphs are available in TortoiseSVN, then this job is intellectually only a “copy & paste” from an existing idea.
    Where is the creativity?
    To be positive, I tell you that Subversion is great and you have an inceible power in front of your noise, but you can’t see it.
    Wake up!

  4. Pablo says:

    Do you know whether a huge public subversion repository is available for downloading? It must be 1.5 version or superior. I’m asking about the repository deployment not about the content.
    Please, if you know where to find it please send me and email with the info to
    Thank you very much!

Leave a Reply

Your email address will not be published. Required fields are marked *