summaryrefslogtreecommitdiffstats
path: root/java/sca-contrib/itest/late-reference-resolution/src
diff options
context:
space:
mode:
authorlresende <lresende@13f79535-47bb-0310-9956-ffa450edef68>2009-11-12 00:43:48 +0000
committerlresende <lresende@13f79535-47bb-0310-9956-ffa450edef68>2009-11-12 00:43:48 +0000
commit9425990f532b1152c2d73db96c0f07ef5216a3d1 (patch)
treea8986fc31f96eb02484a0ae9d1c14cfa788e30ac /java/sca-contrib/itest/late-reference-resolution/src
parent40523f9c6cb1f7a785c2dbd2466dc410ae6ddf66 (diff)
Moving 2.x contribs
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@835178 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca-contrib/itest/late-reference-resolution/src')
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddService.java31
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddServiceImpl.java31
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorService.java35
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorServiceImpl.java74
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideService.java28
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideServiceImpl.java30
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyService.java28
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyServiceImpl.java30
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractService.java31
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractServiceImpl.java31
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/META-INF/services/org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory19
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/Calculator.composite41
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/META-INF/sca-contribution.xml24
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/Calculator.composite32
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/META-INF/sca-contribution.xml24
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/Calculator.composite32
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/META-INF/sca-contribution.xml24
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverFactoryImpl.java50
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverImpl.java72
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java97
-rw-r--r--java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/TestRegistryImpl.java40
21 files changed, 0 insertions, 804 deletions
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddService.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddService.java
deleted file mode 100644
index dd7ecb827d..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddService.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * 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 calculator;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-/**
- * The Add service interface
- */
-@Remotable
-public interface AddService {
-
- double add(double n1, double n2);
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddServiceImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddServiceImpl.java
deleted file mode 100644
index e9b7e254e5..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/AddServiceImpl.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * An implementation of the Add service
- */
-public class AddServiceImpl implements AddService {
-
- public double add(double n1, double n2) {
- System.out.println("AddService - add " + n1 + " and " + n2);
- return n1 + n2;
- }
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorService.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorService.java
deleted file mode 100644
index 031fa8b912..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorService.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * 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 calculator;
-
-
-/**
- * The Calculator service interface.
- */
-public interface CalculatorService {
-
- double add(double n1, double n2);
-
- double subtract(double n1, double n2);
-
- double multiply(double n1, double n2);
-
- double divide(double n1, double n2);
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorServiceImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorServiceImpl.java
deleted file mode 100644
index c927500cc7..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorServiceImpl.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * 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 calculator;
-
-import org.oasisopen.sca.annotation.Reference;
-
-
-/**
- * An implementation of the Calculator service.
- */
-public class CalculatorServiceImpl implements CalculatorService {
-
- private AddService addService;
- private SubtractService subtractService;
- private MultiplyService multiplyService;
- private DivideService divideService;
-
- @Reference
- public void setAddService(AddService addService) {
- this.addService = addService;
- }
-
- @Reference
- public void setSubtractService(SubtractService subtractService) {
- this.subtractService = subtractService;
- }
-
- @Reference
- public void setMultiplyService(MultiplyService multiplyService) {
- this.multiplyService = multiplyService;
- }
-
- @Reference
- public void setDivideService(DivideService divideService) {
- this.divideService = divideService;
- }
-
- public double add(double n1, double n2) {
- System.out.println("CalculatorService - add " + n1 + " and " + n2);
- return addService.add(n1, n2);
- }
-
- public double subtract(double n1, double n2) {
- System.out.println("CalculatorService - subtract " + n1 + " and " + n2);
- return subtractService.subtract(n1, n2);
- }
-
- public double multiply(double n1, double n2) {
- System.out.println("CalculatorService - multiply " + n1 + " and " + n2);
- return multiplyService.multiply(n1, n2);
- }
-
- public double divide(double n1, double n2) {
- System.out.println("CalculatorService - divide " + n1 + " and " + n2);
- return divideService.divide(n1, n2);
- }
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideService.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideService.java
deleted file mode 100644
index 30d248208b..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideService.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * The divide service interface
- */
-public interface DivideService {
-
- double divide(double n1, double n2);
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideServiceImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideServiceImpl.java
deleted file mode 100644
index f7ac0b7287..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/DivideServiceImpl.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * An implementation of the Divide service.
- */
-public class DivideServiceImpl implements DivideService {
-
- public double divide(double n1, double n2) {
- return n1 / n2;
- }
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyService.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyService.java
deleted file mode 100644
index 5290605938..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyService.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * The interface for the multiply service
- */
-public interface MultiplyService {
-
- double multiply(double n1, double n2);
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyServiceImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyServiceImpl.java
deleted file mode 100644
index b7dca792b2..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyServiceImpl.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * An implementation of the Multiply service.
- */
-public class MultiplyServiceImpl implements MultiplyService {
-
- public double multiply(double n1, double n2) {
- return n1 * n2;
- }
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractService.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractService.java
deleted file mode 100644
index f03b9b94d4..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractService.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * 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 calculator;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-/**
- * The interface for the multiply service
- */
-@Remotable
-public interface SubtractService {
-
- double subtract(double n1, double n2);
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractServiceImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractServiceImpl.java
deleted file mode 100644
index 1010207154..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractServiceImpl.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * An implementation of the subtract service.
- */
-public class SubtractServiceImpl implements SubtractService {
-
- public double subtract(double n1, double n2) {
- System.out.println("SubtractService - subtract " + n1 + " and " + n2);
- return n1 - n2;
- }
-
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/META-INF/services/org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/META-INF/services/org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory
deleted file mode 100644
index c53b55aacf..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/META-INF/services/org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory
+++ /dev/null
@@ -1,19 +0,0 @@
-# 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.
-
-# Implementation class for the binding extension
-binding.sca.BindingScaEndpointResolverFactoryImpl;model=org.apache.tuscany.sca.assembly.SCABinding
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/Calculator.composite b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/Calculator.composite
deleted file mode 100644
index 378d6e9706..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/Calculator.composite
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * 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.
--->
-<composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
- targetNamespace="http://sample"
- xmlns:sample="http://sample"
- name="CalculatorA">
-
- <component name="CalculatorServiceComponentA">
- <implementation.java class="calculator.CalculatorServiceImpl"/>
- <reference name="addService" target="AddServiceComponentB" />
- <reference name="subtractService" target="SubtractServiceComponentC" />
- <reference name="multiplyService" target="MultiplyServiceComponentA"/>
- <reference name="divideService" target="DivideServiceComponentA" />
- </component>
-
- <component name="MultiplyServiceComponentA">
- <implementation.java class="calculator.MultiplyServiceImpl" />
- </component>
-
- <component name="DivideServiceComponentA">
- <implementation.java class="calculator.DivideServiceImpl" />
- </component>
-
-</composite>
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/META-INF/sca-contribution.xml b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/META-INF/sca-contribution.xml
deleted file mode 100644
index db255e0232..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeA/META-INF/sca-contribution.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * 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.
--->
-<contribution xmlns="http://www.osoa.org/xmlns/sca/1.0"
- targetNamespace="http://sample"
- xmlns:sample="http://sample">
- <deployable composite="sample:CalculatorA"/>
-</contribution> \ No newline at end of file
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/Calculator.composite b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/Calculator.composite
deleted file mode 100644
index 3fb16fa619..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/Calculator.composite
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * 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.
--->
-<composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
- targetNamespace="http://sample"
- xmlns:sample="http://sample"
- name="CalculatorB">
-
- <component name="AddServiceComponentB">
- <implementation.java class="calculator.AddServiceImpl" />
- <service name="AddService">
- <binding.sca uri="http://localhost:8085/AddServiceComponentB"/>
- </service>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/META-INF/sca-contribution.xml b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/META-INF/sca-contribution.xml
deleted file mode 100644
index 130157ac04..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeB/META-INF/sca-contribution.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * 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.
--->
-<contribution xmlns="http://www.osoa.org/xmlns/sca/1.0"
- targetNamespace="http://sample"
- xmlns:sample="http://sample">
- <deployable composite="sample:CalculatorB"/>
-</contribution> \ No newline at end of file
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/Calculator.composite b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/Calculator.composite
deleted file mode 100644
index c615b4355a..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/Calculator.composite
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * 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.
--->
-<composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
- targetNamespace="http://sample"
- xmlns:sample="http://sample"
- name="CalculatorC">
-
- <component name="SubtractServiceComponentC">
- <implementation.java class="calculator.SubtractServiceImpl" />
- <service name="SubtractService">
- <binding.sca uri="http://localhost:8086/SubtractServiceComponentC"/>
- </service>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/META-INF/sca-contribution.xml b/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/META-INF/sca-contribution.xml
deleted file mode 100644
index cba0a5c281..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/main/resources/nodeC/META-INF/sca-contribution.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * 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.
--->
-<contribution xmlns="http://www.osoa.org/xmlns/sca/1.0"
- targetNamespace="http://sample"
- xmlns:sample="http://sample">
- <deployable composite="sample:CalculatorC"/>
-</contribution> \ No newline at end of file
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverFactoryImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverFactoryImpl.java
deleted file mode 100644
index e4bd3035e2..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverFactoryImpl.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * 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 binding.sca;
-
-import org.apache.tuscany.sca.assembly.Binding;
-import org.apache.tuscany.sca.assembly.Endpoint;
-import org.apache.tuscany.sca.assembly.SCABinding;
-import org.apache.tuscany.sca.core.ExtensionPointRegistry;
-import org.apache.tuscany.sca.endpointresolver.EndpointResolver;
-import org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory;
-
-/**
- * The factory for creating endpoint Binding providers
- *
- * @version $Rev$ $Date$
- */
-public class BindingScaEndpointResolverFactoryImpl implements EndpointResolverFactory<SCABinding> {
-
- private ExtensionPointRegistry extensionPoints;
-
- public BindingScaEndpointResolverFactoryImpl(ExtensionPointRegistry extensionPoints) {
- this.extensionPoints = extensionPoints;
- }
-
- public EndpointResolver createEndpointResolver(Endpoint endpoint, Binding binding) {
-
- return new BindingScaEndpointResolverImpl(extensionPoints, endpoint, binding);
- }
-
- public Class<SCABinding> getModelType() {
- return SCABinding.class;
- }
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverImpl.java
deleted file mode 100644
index c6e0689837..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverImpl.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * 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 binding.sca;
-
-
-import java.util.logging.Logger;
-
-import org.apache.tuscany.sca.assembly.Binding;
-import org.apache.tuscany.sca.assembly.Endpoint;
-import org.apache.tuscany.sca.assembly.SCABinding;
-import org.apache.tuscany.sca.core.ExtensionPointRegistry;
-import org.apache.tuscany.sca.endpointresolver.EndpointResolver;
-
-import calculator.LateReferenceResolutionTestCase;
-
-/**
- * The endpoint resolver allows unresolved endpoints to be plumbed into
- * the runtime start and message send processing as a hook to late resolution
- * of target services
- *
- * @version $Rev$ $Date$
- */
-public class BindingScaEndpointResolverImpl implements EndpointResolver {
-
- private final static Logger logger = Logger.getLogger(BindingScaEndpointResolverImpl.class.getName());
-
- private Endpoint endpoint;
- private SCABinding binding;
-
- public BindingScaEndpointResolverImpl(ExtensionPointRegistry extensionPoints,
- Endpoint endpoint,
- Binding binding) {
- this.endpoint = endpoint;
- this.binding = (SCABinding)binding;
- }
-
- public void start(){
- // do nothing
- }
-
- public void resolve() {
- if (endpoint.isUnresolved()){
- // I can cheat here because I know this test only has
- // SCA Bindings in it so all I have to do it find the URL
- // of the endpoint
- String targetURL = LateReferenceResolutionTestCase.registry.locateService(endpoint.getTargetName());
- binding.setURI(targetURL);
- endpoint.setSourceBinding(binding);
- }
- }
-
- public void stop(){
- // do nothing
- }
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java b/java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java
deleted file mode 100644
index 74e01259e2..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * 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 calculator;
-
-
-import java.io.File;
-
-import junit.framework.Assert;
-
-import org.apache.tuscany.sca.node.Client;
-import org.apache.tuscany.sca.node.Contribution;
-import org.apache.tuscany.sca.node.Node;
-import org.apache.tuscany.sca.node.NodeFactory;
-import org.apache.tuscany.sca.node.launcher.DomainManagerLauncher;
-import org.junit.AfterClass;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-/**
- * Runs a distributed domain in a single VM by using and in memory
- * implementation of the distributed domain
- */
-public class LateReferenceResolutionTestCase {
-
- private static Node nodeA;
- private static Node nodeB;
- private static Node nodeC;
-
- private static CalculatorService calculatorService;
-
- public static TestRegistryImpl registry = new TestRegistryImpl();
-
- @BeforeClass
- public static void init() throws Exception {
-
- try {
- System.out.println("Setting up domain");
-
-
- NodeFactory nodeFactory = NodeFactory.newInstance();
- nodeC = nodeFactory.createNode(new File("src/main/resources/nodeC/Calculator.composite").toURL().toString(),
- new Contribution("NodeC",
- new File("src/main/resources/nodeC").toURL().toString()));
- nodeB = nodeFactory.createNode(new File("src/main/resources/nodeB/Calculator.composite").toURL().toString(),
- new Contribution("NodeB",
- new File("src/main/resources/nodeB").toURL().toString()));
- nodeA = nodeFactory.createNode(new File("src/main/resources/nodeA/Calculator.composite").toURL().toString(),
- new Contribution("NodeA",
- new File("src/main/resources/nodeA").toURL().toString()));
-
- nodeC.start();
- nodeB.start();
- nodeA.start();
-
- Client client = (Client)nodeA;
- calculatorService =
- client.getService(CalculatorService.class, "CalculatorServiceComponentA");
-
- } catch(Exception ex){
- System.err.println(ex.toString());
- }
-
- }
-
- @AfterClass
- public static void destroy() throws Exception {
- nodeC.stop();
- nodeB.stop();
- nodeA.stop();
- }
-
- @Test
- public void testCalculator() throws Exception {
-
- // Calculate
- Assert.assertEquals(calculatorService.add(3, 2), 5.0);
- Assert.assertEquals(calculatorService.subtract(3, 2), 1.0);
- Assert.assertEquals(calculatorService.multiply(3, 2), 6.0);
- Assert.assertEquals(calculatorService.divide(3, 2), 1.5);
- }
-}
diff --git a/java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/TestRegistryImpl.java b/java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/TestRegistryImpl.java
deleted file mode 100644
index 57afc9ea50..0000000000
--- a/java/sca-contrib/itest/late-reference-resolution/src/test/java/calculator/TestRegistryImpl.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * 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 calculator;
-
-/**
- * A dummy domain registry component
- */
-public class TestRegistryImpl {
-
- public String locateService(String targetServiceName){
- String targetURL = null;
-
- // In reality of course a registry would have to be initialized
- // with the real target service endpoints but in this test
- // we know what they are going to be ahead of time
- if (targetServiceName.equals("AddServiceComponentB")){
- targetURL = "http://localhost:8085/" + targetServiceName;
- } else if (targetServiceName.equals("SubtractServiceComponentC")){
- targetURL = "http://localhost:8086/" + targetServiceName;
- }
-
- return targetURL;
- }
-}