Tag Library Hell Rant 2

Wait, I'm not done yet, but editing my previous post is a pain because of the embedded code. I've got a few more points to make about how hellish Tag Libraries are.

The first is if you look at this quote from the O'Reilly article I was talking about before concerning the JSTL Expression Language:

What you don't find in the EL are statements such as assignments, if/else, or while. Action elements are used for this type of functionality in JSP, and the EL is not intended to be a general-purpose programming language, just a data access language.

Whhaaatt? And tags ARE supposed to be for general purpose programming?!?! This is incredibly flawed thinking. XML is NOT a programming language! It's hideous, it's verbose, it's bloated, it's impossible.

Secondly, even though the JSTL is an attempt to bring some order to the chaos of Tag Libs, every app server out there (or MVC system like Struts or WebWork) ends up adding their own tags. It's like learning a new programming language every time you switch servers. You've just thrown portability out the window, unless you can somehow guarantee to always use open libraries, which you can't. Tag libs are, like XML in general, a waking nightmare that's going to cause LESS interop in the short term than more. There are already hundreds of individual tags developed on the Jakarta site alone. All of them hiding or showing various parts of the APIs sitting behind them, and most doing a really horrible job at that. If I want access to a database, for example, I'll open a freakin SQL Connection and get it. I'm not going to use a tag to do the same thing.

It's all about time and maintainability. Tags are not saving any time and aren't increasing maintainability. In fact, I'd say they are doing the exact opposite.

Ugh. I know I'm fighting the tides here, or baying at the moon, but just say no!

-Russ

< Previous         Next >