A
recent post by @raganwald that enjoyed Hacker News fame touched on a subject that I agree with: programming has a pop culture. It's important to be using the correct and most trendy APIs and avoid "doing it wrong," which is the ultimate shame.
Friends and I sometimes joke that according to HN, Ruby is old and busted and the new hotness is node.js. For this week.
In making his point, but almost in passing, @raganwald linked to a particularly good argument against XML written—it's offline right now, so I am just guessing here—some ten years ago.
I remember XML's heyday. I would be asked silly abstract things like "How can we use more XML?" Or, "Can we store that in XML?" I was working in Java, and it may come as a surprise to those of you who think
Java == XML
that at the time, Java and XML was a nightmarish pairing. It seemed there were a dozen parsers and as many people preaching the correct way.
At the time, I was skeptical but tried to keep an open mind about XML. Frankly, I was happiest to just ignore it and focus on real requirements. But being asked to use it for the sake of using it tainted my opinion permanently. I ended up disliking it in 2000 and I still dislike it today.
XML's popularity coincided with the unhappy dominion of "Java 2 Enterprise Edition," something I thankfully avoided for the most part. At the time, my colleagues and I focused on the "good parts" (or I should say, the "workable parts") which were JDBC, Java Servlets, and a few others. We never touched EJB.
Enterprise Java became enamored with XML, but we essentially side-stepped both.
Once XML's years of undeserved fame subsided, I had been lucky enough to limit my XML usage to
web.xml
deployment descriptors and the cheerless mire of build tools. With Java's long-overdue Servlet 3.0 spec (2009), even
web.xml
became a thing of the past.
It has now been years since I've had to seriously dig into an XML file. Today, I can develop, build, and deploy Java web-apps with no XML.
So I smirk and frown when I see the programming pop-culture has encoded
Java == XML
into its collective urban dictionary. It's a lazy criticism levied by proponents of trendier platforms to dismiss otherwise-compelling data demonstrating advantages of Java and its JVM. It's similar to picking on the names of classes in Spring. Not all of us use Spring.
Java, like anything that endures more than a few years in the technology space, needs to periodically shed its cruft.
That's a separate matter.