developer.com
Search EarthWeb
CodeGuru | Gamelan | Jars | Wireless | Discussions
Navigate developer.com
Architecture & Design  
Database  
Java
Languages & Tools
Microsoft & .NET
Open Source  
Project Management  
Security  
Techniques  
Voice  
Web Services  
Wireless/Mobile
XML  
New
 
Technology Jobs  

   Developer.com Webcasts:
  The Impact of Coding Standards and Code Reviews

  Project Management for the Developer

  Defining Your Own Software Development Methodology

  more Webcasts...




See The Winners!




Developer Jobs

Be a Commerce Partner














 


Developer News -
First Major PHP Update in Years Coming Soon    June 25, 2009
Red Hat CEO Calls on Oracle to Keep Java Open    June 25, 2009
Google Widens AdSense for iPhone, Android Apps    June 24, 2009
Eclipse Galileo Releases 33 Open Source Projects    June 24, 2009
Free Tech Newsletter -

AJAX: Asynchronous Java + XML?
By Coach K. Wei

Go to page: Prev  1  2  3  Next  

AJAX Architecture

From a software architecture point of view, following are ways in which AJAX differs from today's Web application architecture by adding a client-side engine:

  1. Use of a client-side engine as an intermediate between the User Interface (UI) and the server;
  2. User activity leads to program calls to the client-side engine instead of a page request to the server;
  3. XML data transfer between server and the client-side engine.

The client engine is the key to the AJAX model. Without this engine, every user event must go back to the server for processing. User interaction is tightly coupled with server communications—the client engine unlocks this dependency. This engine, while running inside a Web browser, gives the browser the "extra" intelligence to perform a "partial screen update" instead of a "full page refresh." This engine also communicates with the server in the background, decoupling user interaction from server communications.

Figure 3: Classic Web Application Architecture

Figure 4: Ajax Architecture

Different Technology Options for AJAX

Considering that AJAX represents a Web application model that is defined by partial screen update and asynchronous communication, there are different technologies for building the AJAX client engine, of which JavaScript, Java, and Flash are the most commonly used. Likewise, these three technologies are the most widely used in building AJAX applications.

The Java approach ("Asynchronous Java + XML")

The Java approach typically uses a browser-based lightweight Java engine for client side processing, such as UI rendering, performing partial screen refresh and asynchronous server communication. In this approach, the UI can be defined using XML, whereas client-side application logic is programmed using standard Java.

Examples available over the Internet include:

The JavaScript/DHTML approach ("Asynchronous JavaScript + XML")

The JavaScript/DHTML approach typically uses a browser-based lightweight JavaScript library for client side processing, such as performing partial screen refresh and asynchronous background network communication. In this approach, the UI is typically defined by using DHTML and client-side application logic is programmed using JavaScript.

Some examples include Google Map (http://map.google.com) and Google Suggest (http://www.google.com/webhp?complete=1&hl=en).

The Flash approach ("Asynchrounous ActionScript + SWF")

The Flash approach typically uses a browser-based Flash engine with an ActionScript library for client side processing. In this approach, the UI is typically defined using SWF (a Macromedia proprietary binary format for defining Flash based movies) on the client side, and the client-side application logic is programmed using ActionScript.

Some examples include BroadMoor Hotel (http://www.broadmoor.com/), a Flash-based interactive hotel reservation system.

Strength and Weakness of Different Options

Each of the three AJAX options has its own strengths and weaknesses, making each one suitable for different applications. The following table summarizes their strengthes and weaknesses:

Option Strength Weakness
Java
  • Robust performance and reliability
  • Ease of maintenance due to object-oriented programming
  • Good for Java developers
Requires Java programming skills
DHTML/JavaScript
  • Fits well with existing HTML Web sites/Web applications
  • Good for DHTML Web developers
  • JavaScript/DHTML code is hard to maintain and not designed for team development
  • Performance and functionality limitations
Flash
  • "Sexy" animations
  • Good for graphics designers
  • ActionScript code is hard to maintain and not designed for team development
  • Performance and functionality limitations

The Java approach is capable of delivering good performance and functionality due to binary execution, multi-threaded computing, and the industrial strength of Java Virtual Machine. Applications written in Java are easy to develop and maintain because of the object-oriented programming nature of Java. It is good for enterprise Java developers who have Java programming skills. On the other hand, the Java programming skills requirement is also its weakness, because developer skill set requirements are higher than scripting. Historically, JVM compatibility in various browsers has been a significant issue for this approach. However, there are solutions available for these problems. One solution is to utilize a lightweight, JDK 1.1-compatible Java engine that is guaranteed to run inside all browser-based JVMs. This Java engine would abstract developers away from the traditional problems, enabling the development and universal deployment of Web applications by leveraging the strength of Java.

Go to page: Prev  1  2  3  Next  


Tools:
Add www.developer.com to your favorites
Add www.developer.com to your browser search box
IE 7 | Firefox 2.0 | Firefox 1.5.x
Receive news via our XML/RSS feed


Architecture & Design Archives






internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Reprints, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs