blob: 4eac989258a47522685fe90f03ee6c4f25b8941d [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../skin/tigris.css" type="text/css">
<link rel="stylesheet" href="../skin/mysite.css" type="text/css">
<link rel="stylesheet" href="../skin/site.css" type="text/css">
<link media="print" rel="stylesheet" href="../skin/print.css" type="text/css">
<title>WebServices - Axis</title>
</head>
<body bgcolor="white" class="composite">
<div id="banner">
<table width="100%" cellpadding="0" cellspacing="0" summary="banner" border="0">
<tbody>
<tr>
<td align="left">
<div class="groupLogo">
<a href="http://ws.apache.org/"><img border="0" class="logoImage" alt="The Apache WebServices Project" src="../images/project-logo.png"></a>
</div>
</td><td nowrap="1" width="100%" align="left">
<div class="projectTitleImg">
<br>
<a href=""><img border="0" class="logoImage" alt="Web Services - Axis" src="../images/wsaxis.png"></a>
</div>
</td><td align="right">
<div class="projectLogo">
<a href="http://ws.apache.org/axis/"><img border="0" class="logoImage" alt="The Apache Axis Project" src="../images/axis3.jpg"></a>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<table width="100%" cellpadding="0" cellspacing="0" border="0" summary="nav" id="breadcrumbs">
<tbody>
<tr class="status">
<td width="100%">&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.apache.org/">Apache</a> | <a href="http://ws.apache.org/">Web Services</a> | <a href="http://ws.apache.org/axis/">Axis</a></td><td nowrap="1" align="right">
<form method="get" action="http://www.google.com/search" target="_blank">Search <input type="hidden" name="sitesearch" value="ws.apache.org"><input type="text" id="query" name="q" size="10"><img class="spacer" src="skin/images/spacer.gif" alt="" width="5" height="1"><input type="submit" value="Go" name="Search">
</form>
</td>
</tr>
</tbody>
</table>
<table id="main" width="100%" cellpadding="8" cellspacing="0" summary="" border="0">
<tbody>
<tr valign="top">
<td id="leftcol">
<div id="navcolumn">
<div class="menuBar">
<div class="menu">
<span class="menuLabel">Axis</span>
<div class="menuItem">
<a href="../index.html">Introduction</a>
</div>
<div class="menuItem">
<a href="../news.html">News</a>
</div>
<div class="menuItem">
<a href="http://wiki.apache.org/ws/FrontPage/Axis">FAQ/Wiki</a>
</div>
<div class="menu">
<span class="menuLabel">Get Involved</span>
<div class="menuItem">
<a href="../overview.html">Overview</a>
</div>
<div class="menuItem">
<a href="../cvs.html">SVN Repository</a>
</div>
<div class="menuItem">
<a href="../mail.html">Mailing Lists</a>
</div>
<div class="menuItem">
<a href="../ref.html">Reference Library</a>
</div>
<div class="menuItem">
<a href="../bugs.html">Bugs</a>
</div>
<div class="menuItem">
<a href="../howtobuild.html">HowToBuildSite</a>
</div>
</div>
<div class="menu">
<span class="menuLabel">Axis (Java)</span>
<div class="menuItem">
<a href="../java/index.html">Documentation</a>
</div>
<div class="menuItem">
<a href="../java/releases.html">Releases</a>
</div>
<div class="menuItem">
<a href="../java/install.html">Installation</a>
</div>
<div class="menuItem">
<a href="../java/user-guide.html">User's Guide</a>
</div>
<div class="menuItem">
<a href="../java/developers-guide.html">Developer's Guide</a>
</div>
<div class="menuItem">
<a href="../java/integration-guide.html">Integration Guide</a>
</div>
<div class="menuItem">
<a href="../java/architecture-guide.html">Architecture Guide</a>
</div>
<div class="menuItem">
<a href="../java/reference.html">Reference Guide</a>
</div>
<div class="menuItem">
<a href="../java/reading.html">Reading Guide</a>
</div>
<div class="menuItem">
<a href="../java/requirements.html">Requirements</a>
</div>
</div>
<div class="menu">
<span class="menuLabel">Axis C++</span>
<div class="menuItem">
<a href="http://ws.apache.org/axis/cpp/index.html">Home</a>
</div>
<div class="menuItem">
<a href="http://ws.apache.org/axis/cpp/documentation.html">Documentation</a>
</div>
<div class="menuItem">
<a href="http://ws.apache.org/axis/cpp/download.html">Download</a>
</div>
<div class="menuItem">
<a href="http://wiki.apache.org/ws/FrontPage/AxisCPP">Wiki Pages</a>
</div>
<div class="menuItem">
<a href="http://ws.apache.org/axis/cpp/who.html">Who we are</a>
</div>
</div>
<div class="menu">
<span class="menuLabel">Downloads</span>
<div class="menuItem">
<a href="../interim.html">Interim Drops</a>
</div>
<div class="menuItem">
<a href="http://svn.apache.org/viewcvs.cgi/webservices/axis/trunk/">Source Code</a>
</div>
</div>
<div class="menu">
<span class="menuLabel">Translation</span>
<div class="menuItem">
<a href="http://ws.apache.org/axis/ja/index.html">Japanese</a>
</div>
</div>
<div class="menu">
<span class="menuLabel">Related Projects</span>
<div class="menuItem">
<a href="http://ws.apache.org/wsif/">WSIF</a>
</div>
<div class="menuItem">
<a href="http://ws.apache.org/juddi/">jUDDI</a>
</div>
<div class="menuItem">
<a href="http://wsdl4j.sourceforge.net">WSDL4J</a>
</div>
<div class="menuItem">
<a href="http://www.uddi4j.org/">UDDI4J</a>
</div>
</div>
<div class="menu">
<span class="menuLabel">Misc</span>
<div class="menuItem">
<a href="../who.html">Who we are</a>
</div>
<div class="menuItem">
<a href="../contact.html">Contact</a>
</div>
<div class="menuItem">
<a href="../legal.html">Legal</a>
</div>
<div class="menuItem">
<a href="../docs.html">Notes/Docs</a>
</div>
</div>
</div>
</div>
</div>
</td><td>
<div id="bodycol">
<div class="app">
<div class="h3">
<div class="h3">
<h3>WebServices - Axis - Caching Early Draft</h3>
</div>
<p>
<TABLE WIDTH="100%" border="0" cellspacing="80">
<TR>
<TD ALIGN="CENTER">
<H1>
Draft Proposal of<br>
Caching Mechanism for Axis<br>
as a JAX-RPC runtime system<br>
</H1>
</TD>
</TR>
<TR>
<TD ALIGN="CENTER">
<H2>
Early draft 2<br>
25 Aug, 2003
</H2>
</TD>
</TR>
<TR>
<TD ALIGN="CENTER">
<H2>
Toshiyuki Kimura<br>
Apache Axis Committer<br>
toshi@apache.org
</H2>
</TD>
</TR>
</TABLE>
<hr>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT"><a name="page2"></a>- Page 2 -</TD>
</TR>
</TABLE>
<H2>Table of Contents</H2>
<P>
<TABLE BORDER="0" cellspacing="20">
<TR>
<TD>
<a href="#section1">1. INTRODUCTION</a>
<br>
<a href="#section1.1">1.1 DESIGN GOALS</a>
<br>
<a href="#section1.2">1.2 ACKNOWLEDGMENTS</a>
<br>
<a href="#section1.3">1.3 STATUS</a>
<br>
<a href="#section1.4">1.4 NOTATIONAL CONVENTIONS</a>
<br>
<a href="#section2">2. CACHING MECHANISM USECASE</a>
<br>
<a href="#section2.1">2.1 WEATHER FORECAST SERVICE</a>
<br>
<a href="#section2.1.1">2.1.1 Service Description</a>
<br>
<a href="#section2.1.2">2.1.2 Service Use</a>
<br>
<a href="#section2.2">2.2 CACHING MECHANISMS</a>
<br>
<a href="#section2.2.1">2.2.1 Service Client</a>
<br>
<a href="#section2.2.2">2.2.2 Server Side</a>
<br>
<a href="#section3">3. REQUIREMENTS</a>
<br>
<a href="#section4">4. REFERENCE</a>
<br>
<a href="#section5">5. APPENDIX: PROTOTYPE OF CACHING MECHANISM</a>
<br>
<a href="#section6">6. APPENDIX: SAMPLE APPLICATION</a>
<br>
<a href="#section7">7. APPENDIX: UNRESOLVED ISSUES</a>
<br>
</TD>
<TD>
<a href="#page3">------ 3<br>
</a>
<a href="#page3">------ 3<br>
</a>
<a href="#page3">------ 3<br>
</a>
<a href="#page3">------ 3<br>
</a>
<a href="#page3">------ 3<br>
</a>
<a href="#page4">------ 4<br>
</a>
<a href="#page4">------ 4<br>
</a>
<a href="#page4">------ 4<br>
</a>
<a href="#page5">------ 5<br>
</a>
<a href="#page5">------ 5<br>
</a>
<a href="#page5">------ 5<br>
</a>
<a href="#page6">------ 6<br>
</a>
<a href="#page7">------ 7<br>
</a>
<a href="#page7">------ 7<br>
</a>
<a href="#page8">------ 8<br>
</a>
<a href="#page8">------ 8<br>
</a>
<a href="#page9">------ 9<br>
</a>
</TD>
</TR>
</TABLE>
</P>
<HR>
<a name="page3"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 3 -</TD>
</TR>
</TABLE>
<H1>
<a name="section1"></a>1. Introduction</H1>
<DIV>
<p>
At the present time, SOAP is actually famous as a transport-independent protocol. But in fact,
HTTP protocol is the leading binding of SOAP implementations. In addition, a lot of JAX-RPC
implementations use the HTTP POST method for invoking Web Services based on SOAP 1.1
specification. The HTTP POST method is specified in HTTP 1.0 specification (RFC 1945) as
uncacheable. Because of this, SOAP is also uncacheable in the present situation.</p>
<p>
This document proposes a set of APIs for JAX-RPC and Messaging styles to enable the cache
control mechanism in various SOAP implementations.
</p>
</DIV>
<H2>
<a name="section1.1"></a>1.1 Design Goals</H2>
<DIV>
The goals of this document are as follows:<br>
<UL>
<LI>Specify APIs for supporting Caching Mechanism for both Server side and Client side on the
Java platform. Caching Mechanism includes 'Enable/Disable Cache', 'Validate Cache',
'Reload Control', and 'Invalidate Cached Data'.</LI>
<LI>Define protocol-bindings independent of Caching Mechanism for SOAP Messages</LI>
<LI>Support both HTTP POST method and HTTP GET method as cacheable protocol bindings
for SOAP Messaging</LI>
<LI>Support interoperability across heterogeneous platforms and environments</LI>
<LI>Support conformance and interoperability requirements that are testable for an
implementation of this proposal</LI>
</UL>
<H2>
<a name="section1.2"></a>1.2 Acknowledgments</H2>
Satoshi Koyama, Takayuki Nagakura, Kenji Suzuki, and Masashi Takeichi (all from NTT DATA
corporation and its business partners) have provided precious technical input to this document.
<H2>
<a name="section1.3"></a>1.3 Status</H2>
This document is the early draft version of the proposal.
<H2>
<a name="section1.4"></a>1.4 Notational Conventions</H2>
<UL>
<LI>Diagrams follow the standard UML notation</LI>
<LI>Code snippets are not shown in complete form. Refer to the Java docs for complete and
detailed description.</LI>
<LI>Examples are illustrative (non-prescriptive)</LI>
</UL>
</DIV>
<HR>
<a name="page4"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 4 -</TD>
</TR>
</TABLE>
<H1>
<a name="section2"></a>2. Caching Mechanism Usecase</H1>
This chapter describes use cases for the Cashing model in a non-prescriptive manner. Later
chapters of this document specify requirements and APIs in a prescriptive manner.
<H2>
<a name="section2.1"></a>2.1 Weather Forecast Service</H2>
<DIV>
The following description uses a weather forecast service example to illustrate Caching
Mechanism concepts.
</DIV>
<DIV ALIGN="CENTER">
<img src="images/image2-1.gif">
</DIV>
<H2>
<a name="section2.1.1"></a>2.1.1 Service Description</H2>
<DIV>
The WeatherForecastService endpoint defines and implements the following Java interface.
</DIV>
<B>Code Example: Interface of WeatherForecastService</B>
<BLOCKQUOTE>
package com.example;<br>
public interface WeatherForecastProvider extends java.rmi.Remote {<br>
int getChanceOfRain ( String areaSymbol ) throws java.rmi.RemoteException;<br>
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br>
}<br>
</BLOCKQUOTE>
The WeatherForecastService has the following features to note:
<UL>
<LI>It returns a chance of rain for the specified area.</LI>
<LI>It forecasts chance of rain from observation data which is provided every 3 hours.</LI>
<LI>The chance of rain won't be changed until the next update of observation data, even though
a client has frequently access to the service.</LI>
</UL>
<hr>
<TABLE WIDTH="100%">
<a name="page5"></a>
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 5 -</TD>
</TR>
</TABLE>
<H2>
<a name="section2.1.2"></a>2.1.2 Service Use</H2>
<DIV>
A service client uses a JAX-RPC service by invoking remote methods on a service endpoint.
The following diagram shows how a service client uses JAX-RPC runtime and Caching
Mechanism.
</DIV>
<DIV ALIGN="CENTER">
<img src="images/image2-1-2.gif">
</DIV>
<H2>
<a name="section2.2"></a>2.2 Caching Mechanisms</H2>
<DIV>
This section describes an overview of Caching Mechanisms.
</DIV>
<H2>
<a name="section2.2.1"></a>2.2.1 Service Client</H2>
<DIV>
The following use case diagram shows how a client-side JAX-RPC runtime system uses local
cached data which is stored by Caching Mechanisms.
</DIV>
<DIV ALIGN="CENTER">
<img src="images/image2-2-1.gif">
</DIV>
<HR>
<a name="page6"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 6 -</TD>
</TR>
</TABLE>
<H2>
<a name="section2.2.2"></a>2.2.2 Server Side</H2>
<DIV>
The diagram shows how a server-side JAX-RPC runtime system informs that a response
message is cacheable to the service client.
</DIV>
<DIV ALIGN="CENTER">
<img src="images/image2-2-2.gif">
</DIV>
<HR>
<a name="page7"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 7 -</TD>
</TR>
</TABLE>
<H1>
<a name="section3"></a>3. Requirements</H1>
<DIV>
This chapter specifies the proposed scope and requirements for the 1.0 version of Caching
Mechanisms. These requirements will be described in more depth in the later chapters.
</DIV>
<B>R01 Protocol Bindings</B>
<UL>
The goal of this document is to enable support for multiple protocol bindings. SOAP 1.1
specification [1] provides a sample for using SOAP in HTTP protocol [4] with HTTP POST
methods. An extended version, SOAP 1.2 [2] adds a scenario by using HTTP GET methods.
<B>Note:</B> HTTP 1.0 [3] does not allow caching for HTTP POST methods, however HTTP 1.1 adds
some additional rules to enable caching mechanisms for HTTP POST methods.
</UL>
<B>R02 Transport</B>
<UL>
As a minimum this caching mechanism is required to support HTTP 1.1 as the transport for
SOAP message. HTTP binding for the SOAP message is based on the SOAP 1.1 specification
[1].
</UL>
<H1>
<a name="section4"></a>4. Reference</H1>
<UL>
<LI>[1] W3C Note: SOAP 1.1: <a href="http://www.w3c.org./TR/SOAP/">http://www.w3c.org./TR/SOAP/</a>
</LI>
<LI>[2] W3C: SOAP 1.2: <a href="http://www.w3c.org/TR/soap12/">http://www.w3c.org/TR/soap12/</a>
</LI>
<LI>[3] HTTP 1.0 <a href="http://www.w3.org/Protocols/rfc1945/rfc1945">http://www.w3.org/Protocols/rfc1945/rfc1945</a>
</LI>
<LI>[4] HTTP 1.1: <a href="http://www.w3.org/Protocols/rfc2616/rfc2616">http://www.w3.org/Protocols/rfc2616/rfc2616</a>
</LI>
</UL>
<HR>
<a name="page8"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 8 -</TD>
</TR>
</TABLE>
<H1>
<a name="section5"></a>5. Appendix: Prototype of Caching mechanism</H1>
<DIV>
In order to demonstrate the feasibility of Caching Mechanisms, I made a prototype of a cache
controller which provides a local cache on the service client side.
</DIV>
<DIV ALIGN="CENTER">
<img src="images/image5.gif">
</DIV>
<DIV>
The hatched areas indicate the extended modules for Apache Axis as a typical JAX-RPC
implementation. The detail of this implementation (i.e. class diagram, sequence diagram, and
Java docs) will be provided after translation and review.
</DIV>
<H1>
<a name="section6"></a>6. Appendix: Sample Application</H1>
<DIV>
This sample application uses the WeatherForecastService to enable a cacheable scenario. When
an end-user sets a location (like as Tokyo, Osaka, or Kyoto) and invokes the service, the
system returns chance of rains for the specified area. Additionally, if the request is cached data
and the cache is still valid data, the response message will be picked up from the cache
repository.
</DIV>
<DIV ALIGN="CENTER">
<img src="images/image6.gif">
</DIV>
<DIV>
<B>Note:</B> The role of the HTTP Header Handler is to set a HTTP protocol header for cache controls.
</DIV>
<HR>
<a name="page9"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 9 -</TD>
</TR>
</TABLE>
<H1>
<a name="section7"></a>7. Appendix: Unresolved issues</H1>
<DIV>
The following items are to be determined.
</DIV>
<TABLE ALIGN="CENTER" BORDER="1" WIDTH="90%">
<TR ALIGN="CENTER">
<TH>ID</TH><TH>Name</TH><TH>Detail (actual state)</TH>
</TR>
<TR>
<TD>1</TD><TD>Dynamic cache-control API</TD><TD>The current version only provides static configurations with
server-config.wsdd.</TD>
</TR>
<TR>
<TD>2</TD><TD>SwA (SOAP Messages with Attachments)</TD><TD>The current version doesn't support caching a response which
has attachment parts.</TD>
</TR>
<TR>
<TD>3</TD><TD>Protocol-bindings independent Caching Mechanism</TD><TD>The current version is a prototype for HTTP bindings. To
create a protocol-bindings independent Caching Mechanism,
the following needs to be done;
<UL>
<LI> Specify a standard SOAP Message header to cache</LI>
<LI> Implement a SOAP Message setter on server side</LI>
<LI> Implement a SOAP Message parser on client side</LI>
</UL>
</TD>
</TR>
</TABLE>
<HR>
<a name="page10"></a>
</HR>
<TABLE WIDTH="100%">
<TR>
<TD ALIGN="RIGHT">Copyright &copy; 2003 Toshiyuki Kimura</TD>
</TR>
<TR>
<TD ALIGN="LEFT">- Page 10 -</TD>
</TR>
</TABLE>
<TABLE BORDER="0" CELLSPACING="100" WIDTH="100%">
<TR>
<TD></TD>
</TR>
<TR>
<TD>
<BLOCKQUATE>
Sun, Sun Microsystems, and Java are trademarks or registered trademarks of
Sun Microsystems, Inc. All other product names mentioned herein are
trademarks of their respective owners.
</BLOCKQUATE>
</TD>
</TR>
</TABLE>
</p>
<div id="pdf" align="right">
<a href="CachingEarlDraft2.pdf"><img alt="PDF" src="../skin/images/pdfdoc.gif" class="skin"><br>
PDF</a>
</div>
</div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
<div id="footer">
<table summary="footer" cellspacing="0" cellpadding="4" width="100%" border="0">
<tbody>
<tr>
<td colspan="2">
<div align="center">
<div class="copyright">
Copyright &copy; 2000-2005&nbsp;The Apache Software Foundation. All rights reserved.
</div>
</div>
</td>
</tr>
<tr>
<td align="left"></td><td align="right">
<div align="right">
<div class="credit"></div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>