I've been working on getting an automatic build setup, including tests so that individual developpers don't have to integrate manually all the time, I find Continuous Integration worthwhile but it's too costly in our current all-manual setup ! I first started using cruisecontrol but when I discovered anthill I quickly switched to it. It's very very easy to use. I just read about maven on another weblog and it seems complicated... is it worth it ? I'm not sure, I think I'll just stick to anthill which suits my need.
Doing this forced me to clean up the jars used in the class path ! Have you ever tried it ? It's a real nightmare : LinkageError on the SAX Document interface, noSuchMethodErrors, etc, etc... This was happening when I was running the unit tests through ANT and had added xalan.jar (Xalan-2) to the classpath so that the JUnitReport task would work. And by the way... the project was using a very old xerces & xalan and not the newest... Since only 3 classes refered to Xalan I decided to upgrade to Xalan-2 and have only one xalan jar for the whole project. The fact that this project was over a year old and no-one had done it before me should have hinted something.
I figured that it was all due to the various jars which include different versions of the same classes or interfaces. For example weblogic.jar from weblogic6.1 contains crimson, jaxp interfaces, an old xerces with a weblogic.apache... package while I had a parser.jar (from sun), a newer xerces & xalan on the classpath... Ok... so I figured out what jars were needed and cleaned the classpath. But I was still getting a linkage error :( After a few hours, I had gotten to the point where I had unjared the weblogic jar and started removing anything to do with XML. And that's where I finally figured it out : the system properties which indicate which parser to use were incorrectly set (or not set...) Ahhhhhhhhhhh ! So I finally added the -D.... to the script running ANT and tada... everything works. Will it work in weblogic ? Well... I guess the XMLRegistry is what sets those properties...I'll see on Monday but I'm confident. I think this is an unacceptable situation. I shouldn't have to spend 3 or 4 hours on this kind of stuff.
Posted by pgirolami76 at February 14, 2003 07:04 PM | TrackBack