tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmar...@apache.org
Subject svn commit: r439841 - in /incubator/tuscany/java/sca: containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/ containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ kernel/core/src/main/java/org/...
Date Sun, 03 Sep 2006 20:31:22 GMT
Author: jmarino
Date: Sun Sep  3 13:31:20 2006
New Revision: 439841

URL: http://svn.apache.org/viewvc?view=rev&rev=439841
Log:
have composites reference connector as prelim changes to composites connecting their children;
early wire post-processing SPI (will change)

Added:
    incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java
  (with props)
    incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java
  (with props)
Modified:
    incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeBuilder.java
    incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeComponent.java
    incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ReferenceInvocationTestCase.java
    incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ServiceInvocationTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultBootstrapper.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultRuntime.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/builder/ConnectorImpl.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/AbstractCompositeComponent.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeBuilder.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeComponentImpl.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/builder/SystemCompositeBuilder.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentImpl.java
    incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/wire/OutboundInvocationChainImpl.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeBuilderTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeComponentTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/java/JavaComponentBuilderTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireResolutionTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/CompositePropagationTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/DuplicateRegistrationTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentResolutionTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeLifecycleTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemObjectRegistrationTestCase.java
    incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/integration/implementation/system/builder/SystemBuilderWireTestCase.java
    incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/extension/CompositeComponentExtension.java
    incubator/tuscany/java/sca/kernel/spi/src/test/java/org/apache/tuscany/spi/extension/CompositeComponentExtensionTestCase.java

Modified: incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeBuilder.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeBuilder.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeBuilder.java
(original)
+++ incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeBuilder.java
Sun Sep  3 13:31:20 2006
@@ -51,8 +51,8 @@
         String name = componentDefinition.getName();
         SpringImplementation implementation = componentDefinition.getImplementation();
         AbstractApplicationContext applicationContext = implementation.getComponentType().getApplicationContext();
-        SpringCompositeComponent<?> component = new SpringCompositeComponent(name,
applicationContext, parent, null
-        );
+        SpringCompositeComponent<?> component =
+            new SpringCompositeComponent(name, applicationContext, parent, connector, null);
         CompositeComponentType<BoundServiceDefinition<? extends Binding>,
             BoundReferenceDefinition<? extends Binding>,
             ? extends Property> componentType = implementation.getComponentType();

Modified: incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeComponent.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeComponent.java
(original)
+++ incubator/tuscany/java/sca/containers/container.spring/src/main/java/org/apache/tuscany/container/spring/impl/SpringCompositeComponent.java
Sun Sep  3 13:31:20 2006
@@ -35,6 +35,7 @@
 import org.apache.tuscany.spi.model.Operation;
 import org.apache.tuscany.spi.model.ServiceContract;
 import org.apache.tuscany.spi.wire.TargetInvoker;
+import org.apache.tuscany.spi.builder.Connector;
 
 import org.springframework.beans.BeansException;
 import org.springframework.beans.factory.BeanFactory;
@@ -64,13 +65,15 @@
      * @param name           the name of the SCA composite
      * @param springContext  the pre-instantiated Spring applicaiton context
      * @param parent         the SCA composite parent
+     * @param connector      the connector to use for wiring children
      * @param propertyValues the values of this composite's Properties
      */
     public SpringCompositeComponent(String name,
                                     AbstractApplicationContext springContext,
                                     CompositeComponent parent,
+                                    Connector connector,
                                     Map<String, Document> propertyValues) {
-        super(name, parent, propertyValues);
+        super(name, parent, connector, propertyValues);
         SCAApplicationContext scaApplicationContext = new SCAApplicationContext();
         springContext.setParent(scaApplicationContext);
         // REVIEW we need to refresh to pick up the parent but this is not optimal

Modified: incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ReferenceInvocationTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ReferenceInvocationTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ReferenceInvocationTestCase.java
(original)
+++ incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ReferenceInvocationTestCase.java
Sun Sep  3 13:31:20 2006
@@ -41,7 +41,7 @@
 
     public void testInvocation() throws Exception {
         AbstractApplicationContext ctx = createSpringContext();
-        SpringCompositeComponent<?> parent = new SpringCompositeComponent("spring",
ctx, null, null);
+        SpringCompositeComponent<?> parent = new SpringCompositeComponent("spring",
ctx, null, null, null);
         parent.start();
         TestBean referenceTarget = new TestBeanImpl();
         Reference reference = createMock(Reference.class);

Modified: incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ServiceInvocationTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ServiceInvocationTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ServiceInvocationTestCase.java
(original)
+++ incubator/tuscany/java/sca/containers/container.spring/src/test/java/org/apache/tuscany/container/spring/impl/ServiceInvocationTestCase.java
Sun Sep  3 13:31:20 2006
@@ -44,7 +44,7 @@
 
     public void testInvocation() throws InvalidServiceContractException {
         AbstractApplicationContext springContext = createSpringContext();
-        SpringCompositeComponent<?> context = new SpringCompositeComponent("parent",
springContext, null, null);
+        SpringCompositeComponent<?> context = new SpringCompositeComponent("parent",
springContext, null, null, null);
         InboundWire<TestBean> inboundWire = ArtifactFactory.createInboundWire("fooService",
TestBean.class);
         OutboundWire<TestBean> outboundWire = ArtifactFactory.createOutboundWire("fooService",
TestBean.class);
         ArtifactFactory.terminateWire(outboundWire);

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultBootstrapper.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultBootstrapper.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultBootstrapper.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultBootstrapper.java
Sun Sep  3 13:31:20 2006
@@ -118,10 +118,10 @@
     public RuntimeComponent<SystemCompositeComponent<?>> createRuntime() {
         DefaultRuntime runtime = new DefaultRuntime();
         SystemCompositeComponentImpl systemComponent =
-            new SystemCompositeComponentImpl(ComponentNames.TUSCANY_SYSTEM, runtime, runtime,
null);
+            new SystemCompositeComponentImpl(ComponentNames.TUSCANY_SYSTEM, runtime, runtime,
null, null);
         runtime.setSystemComponent(systemComponent);
         CompositeComponent<?> rootComponent =
-            new CompositeComponentImpl(ComponentNames.TUSCANY_ROOT, runtime, runtime, null);
+            new CompositeComponentImpl(ComponentNames.TUSCANY_ROOT, runtime, runtime, null,
null);
         runtime.setRootComponent(rootComponent);
         return runtime;
     }

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultRuntime.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultRuntime.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultRuntime.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/bootstrap/DefaultRuntime.java
Sun Sep  3 13:31:20 2006
@@ -53,7 +53,7 @@
      * @param runtimeProperties Property values for the runtime itself
      */
     public DefaultRuntime(Map<String, Document> runtimeProperties) {
-        super(ComponentNames.TUSCANY_RUNTIME, null, null, runtimeProperties);
+        super(ComponentNames.TUSCANY_RUNTIME, null, null, null, runtimeProperties);
     }
 
     protected void setRootComponent(CompositeComponent rootComponent) {

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/builder/ConnectorImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/builder/ConnectorImpl.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/builder/ConnectorImpl.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/builder/ConnectorImpl.java
Sun Sep  3 13:31:20 2006
@@ -83,7 +83,6 @@
                     chain.prepare();
                 }
             }
-
         } else if (source instanceof CompositeComponent) {
             CompositeComponent<?> composite = (CompositeComponent) source;
             if (!composite.isSelfWiring()) {

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/AbstractCompositeComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/AbstractCompositeComponent.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/AbstractCompositeComponent.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/AbstractCompositeComponent.java
Sun Sep  3 13:31:20 2006
@@ -27,6 +27,7 @@
 import org.w3c.dom.Document;
 
 import org.apache.tuscany.spi.CoreRuntimeException;
+import org.apache.tuscany.spi.builder.Connector;
 import org.apache.tuscany.spi.model.Operation;
 import org.apache.tuscany.spi.component.AtomicComponent;
 import org.apache.tuscany.spi.component.CompositeComponent;
@@ -82,13 +83,15 @@
      * @param name            the name of the SCA composite
      * @param parent          the SCA composite parent
      * @param autowireContext the component that should be to resolve autowires
+     * @param connector
      * @param propertyValues  the values of this composite's Properties
      */
     public AbstractCompositeComponent(String name,
                                       CompositeComponent parent,
                                       AutowireComponent autowireContext,
+                                      Connector connector,
                                       Map<String, Document> propertyValues) {
-        super(name, parent, propertyValues);
+        super(name, parent, connector, propertyValues);
         this.autowireContext = autowireContext;
     }
 

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeBuilder.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeBuilder.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeBuilder.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeBuilder.java
Sun Sep  3 13:31:20 2006
@@ -97,7 +97,7 @@
         }
 
         String name = componentDefinition.getName();
-        CompositeComponentImpl<?> context = new CompositeComponentImpl(name, parent,
null, null);
+        CompositeComponentImpl<?> context = new CompositeComponentImpl(name, parent,
null, connector, null);
         for (BoundReferenceDefinition<? extends Binding> referenceDefinition : allBoundReferences)
{
             context.register(builderRegistry.build(context, referenceDefinition, deploymentContext));
         }

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeComponentImpl.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeComponentImpl.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/composite/CompositeComponentImpl.java
Sun Sep  3 13:31:20 2006
@@ -24,6 +24,7 @@
 
 import org.apache.tuscany.core.component.AutowireComponent;
 import org.apache.tuscany.spi.component.CompositeComponent;
+import org.apache.tuscany.spi.builder.Connector;
 
 /**
  * The standard implementation of a composite component. Autowiring is performed by delegating
to the parent composite.
@@ -36,25 +37,36 @@
     public CompositeComponentImpl(String name,
                                   CompositeComponent parent,
                                   AutowireComponent autowireContext,
+                                  Connector connector,
                                   Map<String, Document> propertyValues) {
-        this(name, null, parent, autowireContext, propertyValues);
+        this(name, null, parent, autowireContext, connector, propertyValues);
     }
 
     /**
      * Constructor specifying name and URI.
      *
      * @param name              the name of this Component
-     * @param uri               the unique identifier for this component
-     * @param parent            this component's parent
-     * @param autowireComponent the component that should be used to resolve autowired references
+
+
+     @param uri               the unique identifier for this component
+
+
+      * @param parent            this component's parent
+
+     @param autowireComponent the component that should be used to resolve autowired references
+
+
+      * @param connector
      * @param propertyValues    this composite's Property values
+
      */
     public CompositeComponentImpl(String name,
                                   String uri,
                                   CompositeComponent parent,
                                   AutowireComponent autowireComponent,
+                                  Connector connector,
                                   Map<String, Document> propertyValues) {
-        super(name, parent, autowireComponent, propertyValues);
+        super(name, parent, autowireComponent, connector, propertyValues);
         this.uri = uri;
     }
 

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/builder/SystemCompositeBuilder.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/builder/SystemCompositeBuilder.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/builder/SystemCompositeBuilder.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/builder/SystemCompositeBuilder.java
Sun Sep  3 13:31:20 2006
@@ -94,7 +94,8 @@
         // create the composite component
         String name = componentDefinition.getName();
         AutowireComponent autowireContext = getAutowireContext(parent);
-        SystemCompositeComponent<?> context = new SystemCompositeComponentImpl(name,
parent, autowireContext, null);
+        SystemCompositeComponent<?> context =
+            new SystemCompositeComponentImpl(name, parent, autowireContext, connector, null);
         for (ComponentDefinition<? extends Implementation> childComponentDefinition
: allComponents) {
             context.register(builderRegistry.build(context, childComponentDefinition, deploymentContext));
         }

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentImpl.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentImpl.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentImpl.java
Sun Sep  3 13:31:20 2006
@@ -23,6 +23,7 @@
 import org.w3c.dom.Document;
 
 import org.apache.tuscany.spi.component.CompositeComponent;
+import org.apache.tuscany.spi.builder.Connector;
 
 import org.apache.tuscany.core.component.AutowireComponent;
 import org.apache.tuscany.core.component.AutowireResolutionException;
@@ -41,8 +42,9 @@
     public SystemCompositeComponentImpl(String name,
                                         CompositeComponent parent,
                                         AutowireComponent autowireContext,
+                                        Connector connector,
                                         Map<String, Document> propertyValues) {
-        super(name, parent, autowireContext, propertyValues);
+        super(name, parent, autowireContext, connector, propertyValues);
     }
 
     public <S, I extends S> void registerJavaObject(String name, Class<S> service,
I instance)

Modified: incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/wire/OutboundInvocationChainImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/wire/OutboundInvocationChainImpl.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/wire/OutboundInvocationChainImpl.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/main/java/org/apache/tuscany/core/wire/OutboundInvocationChainImpl.java
Sun Sep  3 13:31:20 2006
@@ -73,7 +73,7 @@
                     interceptorChainTail.setNext(channelInterceptor);
                 }
             } else {
-                // no source interceptor chain or source handlers, conntect to target interceptor
chain or channel
+                // no source interceptor chain or source handlers, connect to target interceptor
chain or channel
                 if (targetInterceptorChainHead != null) {
                     interceptorChainHead = targetInterceptorChainHead;
                     interceptorChainTail = targetInterceptorChainHead;

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeBuilderTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeBuilderTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeBuilderTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeBuilderTestCase.java
Sun Sep  3 13:31:20 2006
@@ -66,7 +66,7 @@
 
     @SuppressWarnings("unchecked")
     public void testBuild() throws Exception {
-        CompositeComponent parent = new CompositeComponentImpl(null, null, null, null);
+        CompositeComponent parent = new CompositeComponentImpl(null, null, null, null, null);
 
         CompositeBuilder builder = new CompositeBuilder();
         WireService wireService = new JDKWireService();

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeComponentTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeComponentTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeComponentTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/composite/CompositeComponentTestCase.java
Sun Sep  3 13:31:20 2006
@@ -26,7 +26,7 @@
 public class CompositeComponentTestCase extends TestCase {
 
     public void testSetUri() throws Exception {
-        CompositeComponentImpl<?> component = new CompositeComponentImpl("foo", "foo/bar",
null, null, null);
+        CompositeComponentImpl<?> component = new CompositeComponentImpl("foo", "foo/bar",
null, null, null, null);
         assertEquals("foo/bar", component.getURI());
     }
 }

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/java/JavaComponentBuilderTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/java/JavaComponentBuilderTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/java/JavaComponentBuilderTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/java/JavaComponentBuilderTestCase.java
Sun Sep  3 13:31:20 2006
@@ -55,7 +55,7 @@
 
     @SuppressWarnings("unchecked")
     public void testBuild() throws Exception {
-        CompositeComponent parent = new CompositeComponentImpl(null, null, null, null);
+        CompositeComponent parent = new CompositeComponentImpl(null, null, null, null, null);
 
         PojoComponentType sourceType = new PojoComponentType();
         sourceType.setImplementationScope(Scope.MODULE);

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireResolutionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireResolutionTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireResolutionTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireResolutionTestCase.java
Sun Sep  3 13:31:20 2006
@@ -57,7 +57,7 @@
         autowire = mock(AutowireComponent.class);
         context = new SystemCompositeComponentImpl("test",
             (CompositeComponent) parent.proxy(),
-            (AutowireComponent) autowire.proxy(), null);
+            (AutowireComponent) autowire.proxy(), null, null);
     }
 
     public static interface Foo {

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/AutowireTestCase.java
Sun Sep  3 13:31:20 2006
@@ -37,7 +37,7 @@
      * @throws Exception
      */
     public void testAtomicAutowire() throws Exception {
-        SystemCompositeComponent<?> parent = new SystemCompositeComponentImpl("parent",
null, null, null);
+        SystemCompositeComponent<?> parent = new SystemCompositeComponentImpl("parent",
null, null, null, null);
         parent.start();
 
         List<Class<?>> interfaces = new ArrayList<Class<?>>();
@@ -62,7 +62,7 @@
      * Tests autowiring to a service context which is wired to an atomic context.
      */
     public void testServiceAutowire() throws Exception {
-        SystemCompositeComponent<?> parent = new SystemCompositeComponentImpl("parent",
null, null, null);
+        SystemCompositeComponent<?> parent = new SystemCompositeComponentImpl("parent",
null, null, null, null);
         parent.start();
 
         List<Class<?>> interfaces = new ArrayList<Class<?>>();
@@ -95,7 +95,7 @@
      * Tests autowiring to a reference
      */
     public void testReferenceAutowire() throws Exception {
-        SystemCompositeComponent<?> parent = new SystemCompositeComponentImpl("parent",
null, null, null);
+        SystemCompositeComponent<?> parent = new SystemCompositeComponentImpl("parent",
null, null, null, null);
         parent.start();
 
         Source refSource = new SourceImpl();

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/CompositePropagationTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/CompositePropagationTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/CompositePropagationTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/CompositePropagationTestCase.java
Sun Sep  3 13:31:20 2006
@@ -52,9 +52,9 @@
 
     protected void setUp() throws Exception {
         super.setUp();
-        parent = new SystemCompositeComponentImpl("parent", null, null, null);
-        child1 = new SystemCompositeComponentImpl("child1", parent, null, null);
-        child2 = new SystemCompositeComponentImpl("child2", child1, null, null);
+        parent = new SystemCompositeComponentImpl("parent", null, null, null, null);
+        child1 = new SystemCompositeComponentImpl("child1", parent, null, null, null);
+        child2 = new SystemCompositeComponentImpl("child2", child1, null, null, null);
         child1.register(child2);
         parent.register(child1);
     }

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/DuplicateRegistrationTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/DuplicateRegistrationTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/DuplicateRegistrationTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/DuplicateRegistrationTestCase.java
Sun Sep  3 13:31:20 2006
@@ -35,7 +35,7 @@
 public class DuplicateRegistrationTestCase extends MockObjectTestCase {
 
     public void testDuplicateRegistration() throws Exception {
-        SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null,
null);
+        SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null,
null, null);
         parent.start();
 
         List<Class<?>> interfaces = new ArrayList<Class<?>>();

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentResolutionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentResolutionTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentResolutionTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeComponentResolutionTestCase.java
Sun Sep  3 13:31:20 2006
@@ -36,7 +36,7 @@
 public class SystemCompositeComponentResolutionTestCase extends MockObjectTestCase {
 
     public void testComponentResolution() throws NoSuchMethodException {
-        SystemCompositeComponent parent = new SystemCompositeComponentImpl("foo", null, null,
null);
+        SystemCompositeComponent parent = new SystemCompositeComponentImpl("foo", null, null,
null, null);
         parent.start();
         List<Class<?>> interfaces = new ArrayList<Class<?>>();
         interfaces.add(Source.class);

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeLifecycleTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeLifecycleTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeLifecycleTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemCompositeLifecycleTestCase.java
Sun Sep  3 13:31:20 2006
@@ -34,7 +34,7 @@
 public class SystemCompositeLifecycleTestCase extends MockObjectTestCase {
 
     public void testLifecycle() throws Exception {
-        SystemCompositeComponent composite = new SystemCompositeComponentImpl("foo", null,
null, null);
+        SystemCompositeComponent composite = new SystemCompositeComponentImpl("foo", null,
null, null, null);
         composite.start();
         assertNull(composite.getChild("nothtere"));
         composite.stop();
@@ -55,7 +55,7 @@
         mock.stubs().method("getServiceInterfaces").will(returnValue(interfaces));
         SystemAtomicComponent context = (SystemAtomicComponent) mock.proxy();
 
-        SystemCompositeComponent composite = new SystemCompositeComponentImpl("foo", null,
null, null);
+        SystemCompositeComponent composite = new SystemCompositeComponentImpl("foo", null,
null, null, null);
         composite.start();
         composite.register(context);
 

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemObjectRegistrationTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemObjectRegistrationTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemObjectRegistrationTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/implementation/system/component/SystemObjectRegistrationTestCase.java
Sun Sep  3 13:31:20 2006
@@ -59,7 +59,7 @@
 
     protected void setUp() throws Exception {
         super.setUp();
-        systemContext = new SystemCompositeComponentImpl(null, null, null, null);
+        systemContext = new SystemCompositeComponentImpl(null, null, null, null, null);
         systemContext.start();
         systemContext.publish(new CompositeStart(this, null));
     }

Modified: incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/integration/implementation/system/builder/SystemBuilderWireTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/integration/implementation/system/builder/SystemBuilderWireTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/integration/implementation/system/builder/SystemBuilderWireTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/core/src/test/java/org/apache/tuscany/core/integration/implementation/system/builder/SystemBuilderWireTestCase.java
Sun Sep  3 13:31:20 2006
@@ -65,7 +65,7 @@
         Connector connector = new ConnectorImpl();
         SystemComponentBuilder builder = new SystemComponentBuilder();
 
-        SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null,
null);
+        SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null,
null, null);
 
         ComponentDefinition<SystemImplementation> targetComponentDefinition = MockComponentFactory.createTarget();
         ComponentDefinition<SystemImplementation> sourceComponentDefinition =
@@ -103,8 +103,9 @@
         SystemComponentBuilder builder = new SystemComponentBuilder();
         SystemBindingBuilder bindingBuilder = new SystemBindingBuilder();
 
-        SystemCompositeComponent grandParent = new SystemCompositeComponentImpl("grandparent",
null, null, null);
-        SystemCompositeComponent parent = new SystemCompositeComponentImpl("parent", grandParent,
grandParent, null);
+        SystemCompositeComponent grandParent = new SystemCompositeComponentImpl("grandparent",
null, null, null, null);
+        SystemCompositeComponent parent = new SystemCompositeComponentImpl("parent", grandParent,
grandParent, null,
+            null);
 
         // create a context in the grandparent that the reference will be autowired to
         ComponentDefinition<SystemImplementation> targetComponentDefinition = MockComponentFactory.createTarget();
@@ -149,7 +150,7 @@
         SystemComponentBuilder builder = new SystemComponentBuilder();
         SystemBindingBuilder bindingBuilder = new SystemBindingBuilder();
 
-        SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null,
null);
+        SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null,
null, null);
 
         BoundServiceDefinition<SystemBinding> serviceDefinition = MockComponentFactory.createBoundService();
         ComponentDefinition<SystemImplementation> componentDefinition = MockComponentFactory.createTarget();

Added: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java?view=auto&rev=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java
(added)
+++ incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java
Sun Sep  3 13:31:20 2006
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tuscany.spi.builder;
+
+/**
+ * Denotes an error during post-processing of a wire
+ *
+ * @version $Rev$ $Date$
+ */
+public class PostProcessingException extends BuilderException {
+    public PostProcessingException() {
+    }
+
+    public PostProcessingException(String message) {
+        super(message);
+    }
+
+    public PostProcessingException(String message, Throwable cause) {
+        super(message, cause);
+    }
+
+    public PostProcessingException(Throwable cause) {
+        super(cause);
+    }
+}

Propchange: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/PostProcessingException.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java?view=auto&rev=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java
(added)
+++ incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java
Sun Sep  3 13:31:20 2006
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tuscany.spi.builder;
+
+import org.apache.tuscany.spi.wire.InboundWire;
+import org.apache.tuscany.spi.wire.OutboundWire;
+
+/**
+ * Implementations are called after inbound and outbound wires are decorated with policy
and before they are connected.
+ *
+ * @version $Rev$ $Date$
+ */
+public interface WirePostProcessor {
+
+    /**
+     * @param source
+     * @param target
+     */
+    <T> void process(OutboundWire<T> source, InboundWire<T> target);
+
+    /**
+     * @param source
+     * @param target
+     */
+    <T> void process(InboundWire<T> source, OutboundWire<T> target);
+
+}

Propchange: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/builder/WirePostProcessor.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/extension/CompositeComponentExtension.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/extension/CompositeComponentExtension.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/extension/CompositeComponentExtension.java
(original)
+++ incubator/tuscany/java/sca/kernel/spi/src/main/java/org/apache/tuscany/spi/extension/CompositeComponentExtension.java
Sun Sep  3 13:31:20 2006
@@ -44,6 +44,7 @@
 import org.apache.tuscany.spi.wire.InboundWire;
 import org.apache.tuscany.spi.wire.OutboundWire;
 import org.apache.tuscany.spi.wire.TargetInvoker;
+import org.apache.tuscany.spi.builder.Connector;
 
 /**
  * An extension point for composite components, which new types may extend
@@ -56,12 +57,16 @@
     protected final List<Service> services = new ArrayList<Service>();
     protected final List<Reference> references = new ArrayList<Reference>();
     protected final Map<String, Document> propertyValues;
+    protected final Connector connector;
     protected boolean selfWiring;
 
-    protected CompositeComponentExtension(String name, CompositeComponent<?> parent,
+    protected CompositeComponentExtension(String name,
+                                          CompositeComponent<?> parent,
+                                          Connector connector,
                                           Map<String, Document> propertyValues) {
         super(name, parent);
         this.propertyValues = propertyValues;
+        this.connector = connector;
     }
 
     public boolean isSelfWiring() {

Modified: incubator/tuscany/java/sca/kernel/spi/src/test/java/org/apache/tuscany/spi/extension/CompositeComponentExtensionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/kernel/spi/src/test/java/org/apache/tuscany/spi/extension/CompositeComponentExtensionTestCase.java?view=diff&rev=439841&r1=439840&r2=439841
==============================================================================
--- incubator/tuscany/java/sca/kernel/spi/src/test/java/org/apache/tuscany/spi/extension/CompositeComponentExtensionTestCase.java
(original)
+++ incubator/tuscany/java/sca/kernel/spi/src/test/java/org/apache/tuscany/spi/extension/CompositeComponentExtensionTestCase.java
Sun Sep  3 13:31:20 2006
@@ -211,7 +211,7 @@
 
     private class Composite<T> extends CompositeComponentExtension<T> {
         public Composite() {
-            super(null, null, null);
+            super(null, null, null, null);
         }
 
         public void setScopeContainer(ScopeContainer scopeContainer) {



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


Mime
View raw message