You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by jm...@apache.org on 2006/05/30 01:47:53 UTC

svn commit: r410164 [4/4] - in /incubator/tuscany/sandbox/jboynes/sca: containers/container.groovy/src/main/java/org/apache/tuscany/container/groovy/ containers/container.groovy/src/test/java/org/apache/tuscany/container/groovy/ containers/container.ja...

Copied: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/InboundWire.java (from r410152, incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceWire.java)
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/InboundWire.java?p2=incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/InboundWire.java&p1=incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceWire.java&r1=410152&r2=410164&rev=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceWire.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/InboundWire.java Mon May 29 16:47:49 2006
@@ -18,13 +18,13 @@
 
 /**
  * Implementations are responsible for managing the service side of a wire, including the invocation chains
- * associated with each service operation. A <Code>ServiceWire</code> can be connected to another
- * <code>ServiceWire</code> when connecting a {@link org.apache.tuscany.spi.context.ServiceContext} to an
+ * associated with each service operation. A <Code>InboundWire</code> can be connected to another
+ * <code>InboundWire</code> when connecting a {@link org.apache.tuscany.spi.context.ServiceContext} to an
  * {@link org.apache.tuscany.spi.context.AtomicContext}.
  *
  * @version $$Rev$$ $$Date$$
  */
-public interface ServiceWire<T> extends RuntimeWire<T> {
+public interface InboundWire<T> extends RuntimeWire<T> {
 
     /**
      * Returns the name of the target service of the wire
@@ -40,16 +40,16 @@
      * Returns the invocation configuration for each operation on a service specified by a reference or a
      * target service.
      */
-    Map<Method, ServiceInvocationChain> getInvocationChains();
+    Map<Method, InboundInvocationChain> getInvocationChains();
 
     /**
      * Adds the collection of invocation chains keyed by operation
      */
-    void addInvocationChains(Map<Method, ServiceInvocationChain> chains);
+    void addInvocationChains(Map<Method, InboundInvocationChain> chains);
 
     /**
      * Adds the invocation chain associated with the given operation
      */
-    void addInvocationChain(Method method, ServiceInvocationChain chain);
+    void addInvocationChain(Method method, InboundInvocationChain chain);
 
 }

Propchange: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/InboundWire.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/InboundWire.java
------------------------------------------------------------------------------
    svn:keywords = Rev,Date

Copied: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundInvocationChain.java (from r410151, incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationChain.java)
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundInvocationChain.java?p2=incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundInvocationChain.java&p1=incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationChain.java&r1=410151&r2=410164&rev=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationChain.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundInvocationChain.java Mon May 29 16:47:49 2006
@@ -2,13 +2,13 @@
 
 /**
  * A set of interceptors and handlers (contained in request and response message channels) associated with the
- * reference side of a wire for a service operation. Reference invocation chains always start with an {@link
+ * outbound side of a wire for a service operation. Outbound invocation chains always start with an {@link
  * Interceptor} and may contain 0..n {@link MessageHandler}s. <code>MessageHandlers</code> are part of a
  * request or response chainnel, which are invoked prior to and after dispatching to a target instance
  * respectively.
  *
  * @version $$Rev$$ $$Date$$
  */
-public interface ReferenceInvocationChain extends InvocationChain {
+public interface OutboundInvocationChain extends InvocationChain {
 
 }

Copied: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundWire.java (from r410152, incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceWire.java)
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundWire.java?p2=incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundWire.java&p1=incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceWire.java&r1=410152&r2=410164&rev=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceWire.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundWire.java Mon May 29 16:47:49 2006
@@ -16,16 +16,14 @@
 import java.lang.reflect.Method;
 import java.util.Map;
 
-import org.apache.tuscany.spi.QualifiedName;
-
 /**
  * Implementations are responsible for managing the reference side of a wire, including the invocation chains
- * associated with each service operation.  A <code>ReferenceWire</code> is connected to a {@link ServiceWire}
+ * associated with each service operation.  A <code>OutboundWire</code> is connected to a {@link InboundWire}
  * through their invocation chains.
  *
  * @version $$Rev$$ $$Date$$
  */
-public interface ReferenceWire<T> extends RuntimeWire<T> {
+public interface OutboundWire<T> extends RuntimeWire<T> {
 
     /**
      * Returns the name of the source reference
@@ -41,16 +39,16 @@
      * Returns the invocation configuration for each operation on a service specified by a reference or a
      * target service.
      */
-    Map<Method, ReferenceInvocationChain> getInvocationChains();
+    Map<Method, OutboundInvocationChain> getInvocationChains();
 
     /**
      * Adds the collection of invocation chains keyed by operation
      */
-    void addInvocationChains(Map<Method, ReferenceInvocationChain> chains);
+    void addInvocationChains(Map<Method, OutboundInvocationChain> chains);
 
     /**
      * Adds the invocation chain associated with the given operation
      */
-    void addInvocationChain(Method method, ReferenceInvocationChain chains);
+    void addInvocationChain(Method method, OutboundInvocationChain chains);
 
 }

Propchange: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundWire.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/OutboundWire.java
------------------------------------------------------------------------------
    svn:keywords = Rev,Date

Modified: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationHandler.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationHandler.java?rev=410164&r1=410163&r2=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationHandler.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ReferenceInvocationHandler.java Mon May 29 16:47:49 2006
@@ -40,9 +40,9 @@
      */
     private Map<Method, ChainHolder> chains;
 
-    public ReferenceInvocationHandler(Map<Method, ReferenceInvocationChain> invocationChains) {
+    public ReferenceInvocationHandler(Map<Method, OutboundInvocationChain> invocationChains) {
         this.chains = new HashMap<Method, ChainHolder>(invocationChains.size());
-        for (Map.Entry<Method, ReferenceInvocationChain> entry : invocationChains.entrySet()) {
+        for (Map.Entry<Method, OutboundInvocationChain> entry : invocationChains.entrySet()) {
             this.chains.put(entry.getKey(), new ChainHolder(entry.getValue()));
         }
     }
@@ -58,7 +58,7 @@
             e.setIdentifier(method.getName());
             throw e;
         }
-        ReferenceInvocationChain chain = holder.chain;
+        OutboundInvocationChain chain = holder.chain;
         if (chain != null) {
             headInterceptor = chain.getHeadInterceptor();
         }
@@ -118,10 +118,10 @@
      */
     private class ChainHolder {
 
-        ReferenceInvocationChain chain;
+        OutboundInvocationChain chain;
         TargetInvoker cachedInvoker;
 
-        public ChainHolder(ReferenceInvocationChain config) {
+        public ChainHolder(OutboundInvocationChain config) {
             this.chain = config;
         }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceInvocationHandler.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceInvocationHandler.java?rev=410164&r1=410163&r2=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceInvocationHandler.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/ServiceInvocationHandler.java Mon May 29 16:47:49 2006
@@ -24,9 +24,9 @@
      */
     private Map<Method, ChainHolder> chains;
 
-    public ServiceInvocationHandler(Map<Method, ServiceInvocationChain> invocationChains) {
+    public ServiceInvocationHandler(Map<Method, InboundInvocationChain> invocationChains) {
         this.chains = new HashMap<Method, ChainHolder>(invocationChains.size());
-        for (Map.Entry<Method, ServiceInvocationChain> entry : invocationChains.entrySet()) {
+        for (Map.Entry<Method, InboundInvocationChain> entry : invocationChains.entrySet()) {
             this.chains.put(entry.getKey(), new ChainHolder(entry.getValue()));
         }
     }
@@ -42,7 +42,7 @@
             e.setIdentifier(method.getName());
             throw e;
         }
-        ServiceInvocationChain chain = holder.chain;
+        InboundInvocationChain chain = holder.chain;
         if (chain != null) {
             headInterceptor = chain.getHeadInterceptor();
         }
@@ -116,10 +116,10 @@
      */
     private class ChainHolder {
 
-        ServiceInvocationChain chain;
+        InboundInvocationChain chain;
         TargetInvoker cachedInvoker;
 
-        public ChainHolder(ServiceInvocationChain config) {
+        public ChainHolder(InboundInvocationChain config) {
             this.chain = config;
         }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireFactoryService.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireFactoryService.java?rev=410164&r1=410163&r2=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireFactoryService.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireFactoryService.java Mon May 29 16:47:49 2006
@@ -25,12 +25,12 @@
     /**
      * Creates a target-side wire factory
      */
-    public ServiceWire<?> createServiceWire();
+    public InboundWire<?> createServiceWire();
 
     /**
      * Creates a source-side wire factory
      */
-    public ReferenceWire<?> createReferenceWire();
+    public OutboundWire<?> createReferenceWire();
 
     /**
      * Determines whether the given object is a proxy

Modified: incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireService.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireService.java?rev=410164&r1=410163&r2=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireService.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/spi/src/main/java/org/apache/tuscany/spi/wire/WireService.java Mon May 29 16:47:49 2006
@@ -5,8 +5,8 @@
 import org.apache.tuscany.spi.builder.BuilderConfigException;
 
 /**
- * Implementations provide a system service that creates {@link org.apache.tuscany.spi.wire.ReferenceWire}s and
- * {@link org.apache.tuscany.spi.wire.ServiceWire}s. This service is typically resolved through autowire.
+ * Implementations provide a system service that creates {@link org.apache.tuscany.spi.wire.OutboundWire}s and
+ * {@link org.apache.tuscany.spi.wire.InboundWire}s. This service is typically resolved through autowire.
  *
  * @version $$Rev$$ $$Date$$
  */
@@ -18,7 +18,7 @@
      * @param reference the reference to create the wire factory for
      * @throws BuilderConfigException
      */
-    ReferenceWire createReferenceWire(Reference reference) throws BuilderConfigException;
+    OutboundWire createReferenceWire(Reference reference) throws BuilderConfigException;
 
     /**
      * Creates a wire for a given service definition
@@ -26,6 +26,6 @@
      * @param service the service to create the wire factory for
      * @throws BuilderConfigException
      */
-    ServiceWire createServiceWire(Service service) throws BuilderConfigException;
+    InboundWire createServiceWire(Service service) throws BuilderConfigException;
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/test/src/main/java/org/apache/tuscany/test/ArtifactFactory.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/test/src/main/java/org/apache/tuscany/test/ArtifactFactory.java?rev=410164&r1=410163&r2=410164&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/test/src/main/java/org/apache/tuscany/test/ArtifactFactory.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/test/src/main/java/org/apache/tuscany/test/ArtifactFactory.java Mon May 29 16:47:49 2006
@@ -6,14 +6,14 @@
 
 import org.apache.tuscany.core.util.MethodHashMap;
 import org.apache.tuscany.core.wire.InvokerInterceptor;
-import org.apache.tuscany.core.wire.ReferenceInvocationChainImpl;
-import org.apache.tuscany.core.wire.ServiceInvocationChainImpl;
-import org.apache.tuscany.core.wire.jdk.JDKReferenceWire;
-import org.apache.tuscany.core.wire.jdk.JDKServiceWire;
-import org.apache.tuscany.spi.wire.ReferenceInvocationChain;
-import org.apache.tuscany.spi.wire.ReferenceWire;
-import org.apache.tuscany.spi.wire.ServiceInvocationChain;
-import org.apache.tuscany.spi.wire.ServiceWire;
+import org.apache.tuscany.core.wire.OutboundInvocationChainImpl;
+import org.apache.tuscany.core.wire.InboundInvocationChainImpl;
+import org.apache.tuscany.core.wire.jdk.JDKOutboundWire;
+import org.apache.tuscany.core.wire.jdk.JDKInboundWire;
+import org.apache.tuscany.spi.wire.OutboundInvocationChain;
+import org.apache.tuscany.spi.wire.OutboundWire;
+import org.apache.tuscany.spi.wire.InboundInvocationChain;
+import org.apache.tuscany.spi.wire.InboundWire;
 
 /**
  * A factory for creating runtime artifacts to facilitate testing without directly instantiating core
@@ -28,14 +28,14 @@
 
     /**
      * Creates a target wire. After a wire is returned, client code must call
-     * {@link #completeTargetWire(org.apache.tuscany.spi.wire.ServiceWire<T>)}. These two methods have been separated
+     * {@link #completeTargetWire(org.apache.tuscany.spi.wire.InboundWire<T>)}. These two methods have been separated
      * to allow wires to be decorated with interceptors or handlers prior to their completion
      *
      * @param serviceName the service name associated with the wire
      * @param interfaze the interface associated with the wire
      */
-    public static <T> ServiceWire<T> createTargetWire(String serviceName, Class<T> interfaze) {
-        ServiceWire<T> wire = new JDKServiceWire<T>();
+    public static <T> InboundWire<T> createTargetWire(String serviceName, Class<T> interfaze) {
+        InboundWire<T> wire = new JDKInboundWire<T>();
         wire.setBusinessInterface(interfaze);
         wire.setServiceName(serviceName);
         wire.addInvocationChains(createTargetInvocationChains(interfaze));
@@ -45,8 +45,8 @@
     /**
      * Finalizes the target wire
      */
-    public static <T> void completeTargetWire(ServiceWire<T> wire) {
-        for (ServiceInvocationChain chain : wire.getInvocationChains().values()) {
+    public static <T> void completeTargetWire(InboundWire<T> wire) {
+        for (InboundInvocationChain chain : wire.getInvocationChains().values()) {
             // add tail interceptor
             chain.addInterceptor(new InvokerInterceptor());
         }
@@ -57,29 +57,29 @@
      * @param refName the reference name the wire is associated with on the client
      * @param interfaze the interface associated with the wire
      */
-    public static <T> ReferenceWire<T> createReferenceWire(String refName, Class<T> interfaze) {
-        ReferenceWire<T> wire = new JDKReferenceWire<T>();
+    public static <T> OutboundWire<T> createReferenceWire(String refName, Class<T> interfaze) {
+        OutboundWire<T> wire = new JDKOutboundWire<T>();
         wire.setReferenceName(refName);
         wire.addInvocationChains(createSourceInvocationChains(interfaze));
         wire.setBusinessInterface(interfaze);
         return wire;
     }
 
-    private static Map<Method, ReferenceInvocationChain> createSourceInvocationChains(Class<?> interfaze) {
-        Map<Method, ReferenceInvocationChain> invocations = new HashMap<Method, ReferenceInvocationChain>();
+    private static Map<Method, OutboundInvocationChain> createSourceInvocationChains(Class<?> interfaze) {
+        Map<Method, OutboundInvocationChain> invocations = new HashMap<Method, OutboundInvocationChain>();
         Method[] methods = interfaze.getMethods();
         for (Method method : methods) {
-            ReferenceInvocationChain chain = new ReferenceInvocationChainImpl(method);
+            OutboundInvocationChain chain = new OutboundInvocationChainImpl(method);
             invocations.put(method, chain);
         }
         return invocations;
     }
 
-    private static Map<Method, ServiceInvocationChain> createTargetInvocationChains(Class<?> interfaze) {
-        Map<Method, ServiceInvocationChain> invocations = new MethodHashMap<ServiceInvocationChain>();
+    private static Map<Method, InboundInvocationChain> createTargetInvocationChains(Class<?> interfaze) {
+        Map<Method, InboundInvocationChain> invocations = new MethodHashMap<InboundInvocationChain>();
         Method[] methods = interfaze.getMethods();
         for (Method method : methods) {
-            ServiceInvocationChain chain = new ServiceInvocationChainImpl(method);
+            InboundInvocationChain chain = new InboundInvocationChainImpl(method);
             // add tail interceptor
             chain.addInterceptor(new InvokerInterceptor());
             invocations.put(method, chain);



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org