Please join us at the new JavaWorld Q&A Forums. Your existing login will work there. The discussions here are now read-only.


JavaWorld Talkback >> 95537

Pages: 1
Colm Smyth
Unregistered




Java, Flash or AJAX? How to choose...
      #46529 - 04/25/07 06:59 PM

Ok, your choices for rich portable browser-based applications are Java, Flash or DHTML/AJAX. To choose, ask yourself these questions:

1. What data do you want to present? If it's almostly entirely HTML, then DHTML or AJAX is a good choice

2. How much client-side business logic or data-crunching do you want to do? For example, Google Spreadsheet is ok for small simple sheets but it's basically a HTML terminal window - all the logic is server-based, so response times are sluggish as the data is shunted back and forth to Google's web server and presentation capabilities are limited (basic formatting, no charts)

3. Would you like to share code (e.g. libraries for business or value objects) between your client and server? Java is your only option. And yes, Google Web Toolkit will let you convert some Java code to Javascript to run in the browser, but it's scope is very limited. A common language means you can also move functionality from server to client or vice-versa with ease.

4. How easy would you like your design, development and debugging process to be? Let me guess - very easy? Good choice. While AJAX-aware IDE's and design tools are coming, they are far from mature and only cover certain tasks, like placing your display or input widgets and (if you're lucky) handling some of your web remoting needs. On the other hand, the range of Java tools is nothing short of stunning; the free Netbeans and Eclipse tools are excellent, and IntelliJ IDEA is still remarkably advanced and intuitive with nearly telepathic refactoring and completion/intention options.

5. Do you like fast responsive applications? Java is considerably faster than DHTML and the ability to migrate logic from server to client means that you can do more without a network round-trip.

6. Do you need offline support? Standard Java readily supports this today; you need proprietary solutions to do this with AJAX and Flash.

7. Do you need security? Java provides a rich mature security and permissions framework; in contracts, Javascript and browser caching/access model expose new security issues continually. Brendan Eich (designer of Javascript) of Mozilla acknowledges this and advocates a new model (which is not yet available)

So there's only a few reasons why you might choose Flash or AJAX:
  • your customers have specifically rejected Java; check the above questions with them first so they know what's involved with Flash or AJAX (essentially, greater cost and significantly greater risk)
  • speed of startup outweighs all the above listed considerations; AJAX probably wins in this case but transferring Javascript, HTML and XML across the web is not for free; run a debugging proxy behind your browser and watch the kilobytes fly when starting say GMail or Google Spreadsheet
  • you're building an application that primarily involves graphical content or animation; Flash is a natural in this domain with excellent support from content authoring tools


This post is also available on the S'Mythology blog.


Post Extras: Print Post   Remind Me!   Notify Moderator  
Pages: 1



Extra information
0 registered and 1 anonymous users are browsing this forum.

Moderator:   

Print Topic

Forum Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is disabled
      UBBCode is enabled

Rating:
Topic views: 3679

Rate this topic

Jump to

Contact us JavaWorld

Powered by UBB.threads™ 6.5.5