The Source for Java Technology Collaboration




AJAX Portlet

This sample is referred to in the technical article "Best Practices for AJAX and JSR 168 Portlets". Here you will find a detailed review of how AJAX (using DOJO) can be implemented in a JSR-168 portlet.

The portlet displays fictional invoices for the Adventure Sports Cafe featured in the enterprise sample shipped with Sun Java System Portal Server.

When the user selects a invoice number in the drop-down box, an asynchronous request is make by the javascript client to a servlet bundled with the portlet application. This sample servlet serves up static html for the invoice, but you can picture how this servlet could instead query some other back-end data source. The portlet leverages the ability of the portlet and servlet in the same web application (war) to share data through the PortletSession?/HttpSession. Refer to below diagram from the technical article.

NOTE: Currently the portlet does not function properly when served up using WSRP. We are currently debugging this.

Tested On

  • Open Source Portlet Container 1.0
  • Apache Pluto 1.0.1
  • Sun Java System Portal Server 7

Topic AJAXPortlet . { Edit | Ref-By | Printable | Diffs r2 < r1 | More }
 XML java.net RSS

Revision r2 - 20 Oct 2007 - 21:05:30 - Main.tmueller
Parents: WebHome