ws-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gene...@ws.apache.org
Subject [Apache Web Services Wiki] Updated: FrontPage/Architecture/Client
Date Wed, 15 Dec 2004 11:22:25 GMT
   Date: 2004-12-15T03:22:24
   Editor: DeepalJayasinghe <deepal@opensource.lk>
   Wiki: Apache Web Services Wiki
   Page: FrontPage/Architecture/Client
   URL: http://wiki.apache.org/ws/FrontPage/Architecture/Client

   no comment

Change Log:

------------------------------------------------------------------------------
@@ -1,18 +1,127 @@
 = Client Side API =
 
-== Requirements ==
+== Client Side Architecture ==
 
-== Wish List ==
+=== What we provide ===
+ * Synchronous Invocation
+ * Asynchronous Invocation using callbacks, still the transport is synchronous
+ * Asynchronous Invocation using callbacks, transport is also asynchronous -addressing information
is required.
 
-== Sub Components ==
 
- * Client API
- * Sync programming model
- * Async Programming model
-
-== Client API ==
-TODO
-== Sync programming model ==
-TODO
-== Async Programming model ==
-TODO
+=== API for the Client ===
+The API provided for the client is mainly by the Call. Followings are the methods that the
call will provide initially.
+
+{{{
+public class Call{
+
+public void setTargetURL(URL);
+public void setAction(String);
+public void setListenerTransport(String);
+public invokeInOnly(SOAPEnvelope);	
+public SOAPEnvelope  invokeInOutSync(SOAPEnvelope);
+public void inovkeInOutAsync(SOAPEnvelope, Callback);
+}
+
+}}}
+
+{{{
+public interface Callback{ 
+void onComplete(AsyncResult);
+}
+}}}
+
+{{{
+public class AyncResult{
+SOAPEnvelope getResponseEnvelope()
+}
+}}}
+
+
+== Possible Message Paths ==
+
+=== One-Way Invocation ===
+The service invocation is a void invocation. No return value.
+{{{
+a -> call.invokeInOnly(SOAPEnvelope)
+b -> engine.send( ..)
+c -> Send the SOAP message
+}}}
+//Asume that the transport is one way e.g. SMTP
+
+
+Code Snippet:
+{{{
+call.setTargetURL(URL)
+call.setAction(String)
+call.invokeInOnly(SOAPEnvelope)
+}}}
+
+=== InOutSynchronous Invocation ===
+The service method has a response and the communication happens synchronously using a bi-directional
protocol. Client hangs until the response (or fault) is returned.
+
+{{{
+a -> call.invokeInOutSync(SOAPEnvelope)
+b- > engine.send (..)
+c -> Send the SOAP message
+d -> Receive the response over the synchronous transport
+w -> ProviderX will be called as the last step in engine.receive(..) 
+e -> provider returns       
+f -> Call hand over the response to the client
+
+}}}
+Code Snippet:
+
+{{{
+call.setTargetURL(URL)
+call.setAction(String)
+SOAPEnvelope env=call.invokeInOutSync(SOAPEnvelope)
+}}}
+
+
+=== InOutAynchronous Invocation ===
+The service method has a response and the communication happens synchronously using a bi-directional
protocol. Client DOES NOT hang until the response (or fault) is returned. Client uses callback
mechanism to retrieve the response. Call API uses threads from a thread pool for each invocation.
+
+{{{
+a -> call.invokeInOutAsync(SOAPEnvelope, callbackObj)
+p -> correlator.addCorrelationInfor(msgID,allbackObjRef)
+b- > engine.send (..)
+c -> Send the SOAP message
+d -> Receive the response over the synchronous transport
+w -> ProviderX will be called as the last step in engine.receive(..) 
+q -> correlator.getCorrelationInfo(msgID)
+g -> callbackObj.onComplet()
+}}}
+
+Code Snippet:
+{{{
+call.setTargetURL(URL)
+call.setAction(String)
+call.invokeInOutAsync(SOAPEnvelope, Callback)
+}}}
+
+=== InOutAynchronous Invocation with One way transport ===
+The service method has a response and the communication happens Aynchronously using a uni-directional
protocol. Client DOES NOT hang until the response (or fault) is returned. Client uses callback
mechanism to retrieve the response. Call API uses threads from a thread pool for each invocation.
+{{{
+a -> call.invokeInOutAsync(SOAPEnvelope, callbackObj)
+p -> correlator.addCorrelationInfor(msgID,allbackObjRef)
+b- > engine.send (..)
+c -> Send the SOAP message
+r -> Receive the response by the listener
+s -> engine.receive(..)
+w -> ProviderX will be called as the last step in engine.receive(..) 
+q -> correlator.getCorrelationInfo(msgID)
+g -> callbackObj.onComplet()
+}}}
+
+Code Snippet:
+{{{
+call.setTargetURL(URL)
+call.setAction(String)
+call.setListenerTransport(“http”)
+call.invokeInOutAsync(SOAPEnvelope, Callback)
+}}}
+
+ 
+== Sequence Diagrams ==
+
+ 

Mime
View raw message