Some days you celebrate the little victories, other days, you celebrate the big ones.

Today, I get to celebrate a pretty significant victory, in my humble opinion: I managed to get the ensembl java API to compile and generate a fully operational battle station jar file that works with my Java code.

I know, it doesn’t sound like such a big deal, but that means I worked out all of it’s dependencies, managed to get all of it to compile without errors and THEN managed to fix a bug.  Not bad for a project I thought would take months.  In fact, I’ve even made some significant upgrades, for instance, it now creates a java 1.6 jar file, which should run a bit faster than the original java 1.4.  I’ve also gone through and upgraded some of the code – making it a bit more readable and in the java 1.6 format with “enhanced loops”.  All in all, I’m pretty pleased with this particular piece of work.  Considering I started on friday, and I’ve managed to make headway on my thesis project in the meantime, I’d say I’m doing pretty well.

So, as I said, I get to celebrate a nice little victory…. and then I’ll have to immediately get back to some more thesis writing.


For posterity’s sake, here are the steps required to complete this project:

  1. Get the full package from the Ensembl people. (They have a version that includes the build file and the licence for the software.  The one I downloaded from the web was incomplete.)
  2. Get all of the dependencies.  They are available on the web, but most of them are out of date and new ones can be used.
  3. Figure out that java2html.jar needs to be in ~/.ant/lib/, not in the usual ./lib path
  4. Fix the problem of new data types in AssemblyMapperAdaptorImpl.java. (It’s a 2 line fix, btw.)
  5. Modify the build.properties file to use the latest version of the mysql API, and then copy that to the appropriate ./lib path.
  6. Modify the build.properties file to reflect that you’re generating a custom jar file.
  7. Modify the build.xml to use java 1.6 instead of 1.4
  8. Figure out how to use the ant code.  Turns out both “ant build” and “ant jar” both work.
  9. Note, the project uses a bootstrap manifest file which isn’t available in the source package on the web. If you use that code, you have to modify the build.xml file to generate a custom manifest file, which is actually pretty easy to do.  This isn’t required, however, if you have the full source code.

When you write it out that way, it doesn’t sound like such a big project does it?  I’m debating putting the modified version somewhere like sourceforge, if there’s any interest from the java/bioinformatics community.  Let me know if you think it might be useful.

3 thoughts on “Celebrations

  1. Yes, it would be useful or at least A rime saver so someone else doesnt have to repeat what you’ve done.

  2. Pingback: Java 1.6 based fork of the Ensembl API. | Fejes.ca

Leave a Reply to fejes Cancel reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.