No Experts in Servlet Expert Group
For a very long time, I’ve held a grudge against the servlet spec. This grudge is always amply justified every time I work with servlets. What’s depressing is how easy it is to fall in and start considering all these limitations normal and sensible.
For starters, there’s the astoundingly braindead url-pattern format. Someone clearly went out of their way in coming up with a syntax that hints at some customisability, yet manages to offer the absolute bare minimum. It’s abundantly clear that whoever came up with this format has never done much beyond written a simple ‘howto’, or probably one of the bunch of idiot authors who feel that writing a book about servlets or jsps somehow means they have real world experience with said technology.
It is absolutely impossible to use this limited form of url mapping. I’m not asking for regex support here, which would be overkill, but proper wildcard support, or even ant-style wildcards surely can’t be THAT hard for users to learn or adapt to? Lets not even consider the fact that there’s no way of specifying exclusions (eg, apply this filter to everything except *.html files).
Next up we have the good-on-paper but mostly useless form based auth. It isn’t particularly endowed with customisability, and generally (at least in the early days) had every appserver somehow manage to fuck up their impl of it. It’s particularly disheartening that even something this simple had vendors befuddled, stumbling about like a bunch of retarded children.
This wouldn’t be so bad if there were some sort of programmatic login, that way one could just bypass the whole auth mess and just use the API. Alas, no such luck. The best that the retarded servlet 2.4 group could fart out was a logoff method in 2.4. Maybe by servlet 2.6, they’ll actually start paying attention to users and add the natural complement to a logoff method.
Then we have the cute little inconsistencies that are the signature of brainwashed buffoons everywhere. We have sendRedirect requiring a context path, but forward not requiring one. Consistent API be damned, instead it’s better to force the user to understand that all they’re doing is setting a header and sending back a status code! Heaven forbid servlet container developers are actually forced to do any actual work or make the life of application developers vaguely tolerable. They’re all too busy pimping their own idiotic implementations, in the few spare minutes they have between bouts of trying desperately to milk their book author credentials for all its worth.
September 25th, 2003 at 9:24 am
books?
Are you refering to the extended java tutorials printed out in longform as the complimentary introduction to java that fills up the first 49% of the books pages, followed by 2% of actual content, followed by printed out versions (often with a large-fonted page hungry style) of the API:s even remotedly related to the subject of the book that *no* java professional programming book with self-respect can be without?
The only reason that people buy books is because coworkers frowns upon those who hauls their monitors into the john with them!
September 25th, 2003 at 9:58 am
That’s why I take my Powerbook to the john ;)
September 25th, 2003 at 10:55 am
If you like the Servlets specs, you’ll LOVE the Portlet API!
September 25th, 2003 at 12:17 pm
jsp:include and jsp:forward, which are two things that should make jsp development intuitive and easy and should be two easy things for containers to implement appear to be two things pretty much guaranteed not to work the same between container versions and vendors…or is it just me?
September 25th, 2003 at 8:30 pm
Shit, I think thats twice now I’ve agreed with Hani!
September 25th, 2003 at 8:44 pm
Hmm, now, would that be a good thing, or a bad thing, Lance? ;)
September 26th, 2003 at 9:26 am
well, most of the points you cite are indeed worth to be discussed, but on the other hand, there is MUCH they have done right.
so, i would say they are experts indeed. I have always enjoyed reading those specs, and the success of the servlets concept and its smooth extensibility is quite astonishing.
(anyway, Hani, i like your blog and read it daily :-)
cheers
joe