The View from Hell

I was on a client site today, integrating Rails' Continuous Builder plugin with an existing CruiseControl setup. We're pumping our own custom test reports out as well as rcov HTML reports, and shoving that all into the Build Artifacts directory. We wanted to make a couple of changes to the standard web pages that CC serves out, just to make the pages more suitable to our project. CruiseControl, being a Java app, uses JSPs for the view. Here's what I expect to find when I look at a JSP:

A JSP file that contains a mix of Java and static HTML, whose output is a bunch of HTML and maybe a little CSS thrown in for good measure.

Instead, this is what I find:

The CruiseControl JSP starts by slurping up some XML stored elsewhere and feeding it to an XSL stylesheet. The XSL spits out an HTML page, but the HTML has no HTML in it; its just a big JavaScript block. The JavaScript uses DOM manipulation to write out a combination of HTML and CSS. And some more JavaScript. Really. I'm not making this up.

Somewhere along the way, this must have either seemed like a good idea, or this represents the cruft of a hundred generations. But the sum total effect was that I was so intimidated, I couldn't change the pages even if I had still wanted to. Complexity as Force Field. Shields up, Captain!