CHANNELS
HOME
TOP STORIES
COLUMNS
OPINIONS
ZEICHICK'S TAKE
EMBEDDED NEWS
TEST & QA REPORT
ECLIPSESOURCE
SPECIAL REPORTS
SD TIMES 100
JOB BOARD
EVENTS CALENDAR
RESOURCE CENTER
WEBINAR CENTER
ADVANCED SEARCH
RSS
ON THE WEB
SITE MAP
ADVERTISE
EDITORIAL
PRIVACY POLICY
CONTACT US
REPORT A BUG
PRINT EDITION
SUBSCRIBE NOW!
CURRENT ISSUE
BACK ISSUES
SUBSCRIBER SERVICES
BZ MEDIA
ABOUT US
NEWS
BZ RESEARCH
SYSMANNEWS
ST&P MAGAZINE
STPCON
ECLIPSEWORLD
ADVERTISER LINKS
activePDF
Alexsys
Altova
Amyuni Technologies
Automated QA
Axosoft
Business Objects
Codejock Software
ComponentOne
Coverity
Data Dynamics
Developer Express
dtSearch
Dundas
Dynamsoft
Hewlett-Packard
IBM
Imagix
Infragistics
InstallAware Software
InterSystems
iWay
Kovair
LEAD Technologies
McObject
Microsoft
MKS
No Magic
nsoftware
Parasoft
Pegasus Imaging Corp
Perforce
Prezza Technologies
Programmer's Paradise
Programming Research
Rally Software Dev
Red Gate Software
ScaleOut
Seapine
Serena
Software FX
Sparx Systems
Swell Software
Syncfusion
TechExcel
Telerik
UrbanCode
WANdisco
Xceed Software
LOADING...
LOADING...
AS OF 8/21/2008 7:49PM EST
AJAX Is No Panacea
By
Allen Holub
March 1, 2006 —
Every so often the industry is overcome with a collective madness so pervasive that the sane among us are forced to check ourselves into the asylum. The current embodiment of this principle is AJAX, a technology that all of us will be using sooner rather than later, but a flawed technology nonetheless. AJAX solves a problem that Java solved six years ago, but the Java solution was firmly rejected by the industry. Im speaking of applets. The fact that an applet-based solution to the rich Web client problem wasnt viable is fully Suns fault, but nonetheless, AJAX is really a triumph of politics over thinking.
Since its adoption is inevitable, Ill be looking at various AJAX tools and initiatives on and off for the next few months, but first I want to whine.
The first thing to bear in mind is that AJAX equals JavaScript. An AJAX toolkit is nothing but a massive JavaScript implementation of features that should have been built into the browser. AJAX carries with it all of the massive headaches associated with any language that actively promotes bad program structure. The toolkits are huge blobs of unmaintainable gobbledygook that only the author can understand.
In theory we can just use the toolkit without worrying about the implementation. In practice, the inherent bugginess of all JavaScript programs (and lack of documentation for most of them) forces us to deal with the code. Some of the toolkits are so delicate that you will be loathe to touch them. Moreover, vast amounts of this complexity are centered on just getting the toolkit to work across browsersa problem that Java solves elegantly.
Perhaps the various AJAX initiatives like the recently announced Open AJAX will eventually create something usefulessentially burying JavaScript inside a widget librarybut for now the learning curve is steep indeed. Frankly, the real solution is to just fix the @#@&*%! browsers. Build in a real language thats implemented the same way in every browser, which has a well-thought-out interface toolkit as part of the language. Im not sitting on the edge of my seat waiting for that to happen, so AJAX is whats left.
But wait a minute! We already have a good cross-platform thin-client toolkit: Java! The technology that could have saved the dayJava appletshas fallen off the face of the Earth. Sun abandoned a visionary approach to Java long ago in favor of being led around by the nose by the large corporate clients. Consequently, resources that could have been put into realizing Javas promise of rich-client applications delivered over the Web have been redirected into useless junk like EJB (another good example of the myopic madness I discussed earlier).
There are other issues, too, that create problems with Java. But they could be overcome.
For example, the JRE is way too big for a casual browser to want to download. Theres no reason why a lean and mean JVM, akin to the J2ME JVM, wouldnt solve this problem, but Sun seems unwilling to move in that direction. The succubus of compile-once/run-everywhere is too seductive, even though J2ME is proof that rigid adherence to this principle is nonsensical.
Note, by the way, that some of the objections that people had to applets are still not solved by AJAX. For example, an AJAX toolkit is a massive thingeasily as large as the .class files that you have to download in an applet-based page (but at least the runtime is already in the browser). Neither Java nor AJAX solves this problem. Similarly, because of the cross-browser behavior issues, youll still have to test on every browser, as you had to do with the original AWT applets. No AJAX toolkitparticularly the open-source projects like dojowill solve every client-side behavior problem. For one thing, youll have to augment the toolkit with JavaScript of your own, which will have to be tested in every browser on every platform.
So AJAX is with us whether we like it or not. It doesnt do anything new, but its a juggernaut. Fortunately, there are a few good AJAX toolkits that will help here and thereIll talk about a couple of them in my next columnbut AJAX is not the panacea that the hype would lead us to believe.
Allen Holub is an architect, consultant and instructor in C/C++, Java and OO Design. Reach him at www.holub.com.
EMAIL THIS ARTICLE
SEND FEEDBACK
MORE COLUMNS
 
SUBSCRIBE TODAY!
E-Newsletters:
News on Mon/Thurs.
Test & QA Report
EclipseSource
SUBMIT
 
JOB BOARD
PDF & PRINT EDITION
* Requires Resource Account! 
LOGIN
or
SIGN UP
*
Download Current Issue!
ISSUE 8/15/2008 PDF
*
Need Back Issues?
DOWNLOAD HERE
Receive The Print Edition?
SUBSCRIBE HERE
 
EVENTS CALENDAR
Business of Software 2008
9/3/2008 to 9/4/2008
Boston
Red Gate Software
VSLive New York
9/7/2008 to 9/10/2008
New York City
1105 Media
Interop New York
9/15/2008 to 9/19/2008
New York
TechWeb
VMworld 2008
9/15/2008 to 9/18/2008
Las Vegas
VMware
Mobile Business Expo
9/16/2008 to 9/19/2008
New York City
TechWeb
REGISTER
MORE EVENTS
GET NOTIFIED!
About all of the latest Resources
SD TIMES 100
6th Annual SD Times 100
It's time once again to
recognize the organizations
or individuals that have
demonstrated leadership in
their markets.