summaryrefslogtreecommitdiffstats
path: root/sandbox/svkrish/integrated-calculator/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'sandbox/svkrish/integrated-calculator/src/main')
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddService.java28
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddServiceImpl.java30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorClient.java52
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorService.java35
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorServiceImpl.java70
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideService.java28
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideServiceImpl.java30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyService.java28
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyServiceImpl.java30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractService.java28
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractServiceImpl.java30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/java/calculator/TestSvnProps.java27
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/Calculator.composite67
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.componentType30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.js22
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.componentType30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.groovy22
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.componentType30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.py20
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.componentType30
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.rb21
-rw-r--r--sandbox/svkrish/integrated-calculator/src/main/resources/wsdl/calculator.wsdl87
22 files changed, 775 insertions, 0 deletions
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddService.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddService.java
new file mode 100644
index 0000000000..5a1e7a638a
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddService.java
@@ -0,0 +1,28 @@
+/*
+ * 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 Add service interface
+ */
+public interface AddService {
+
+ double add(double n1, double n2);
+
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddServiceImpl.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddServiceImpl.java
new file mode 100644
index 0000000000..e9c635e3c8
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/AddServiceImpl.java
@@ -0,0 +1,30 @@
+/*
+ * 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) {
+ return n1 + n2;
+ }
+
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorClient.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorClient.java
new file mode 100644
index 0000000000..ff4cd778cf
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorClient.java
@@ -0,0 +1,52 @@
+/*
+ * 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.apache.tuscany.sca.host.embedded.SCADomain;
+
+/**
+ * This client program shows how to create an SCA runtime, start it,
+ * and locate and invoke a SCA component
+ */
+public class CalculatorClient {
+ public static void main(String[] args) throws Exception {
+
+ SCADomain scaDomain = SCADomain.newInstance("Calculator.composite");
+
+ CalculatorService calculatorService =
+ scaDomain.getService(CalculatorService.class, "CalculatorServiceComponent");
+
+ // Calculate
+ System.out.println("**********************************************************");
+ System.out.println("Integrated Calculator Demo.........");
+ System.out.println("**********************************************************");
+ System.out.println("Invoking the 'ADD' service....");
+ System.out.println("3 + 2 = " + calculatorService.add(3, 2));
+ System.out.println("\nInvoking the 'SUBTRACT' service....");
+ System.out.println("3 - 2 = " + calculatorService.subtract(3, 2));
+ System.out.println("\nInvoking the 'MULTIPLY' service....");
+ System.out.println("3 * 2 = " + calculatorService.multiply(3, 2));
+ System.out.println("\nInvoking the 'DIVIDE' service....");
+ System.out.println("3 / 2 = " + calculatorService.divide(3, 2));
+ System.out.println("\n**********************************************************");
+ scaDomain.close();
+ }
+
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorService.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorService.java
new file mode 100644
index 0000000000..ad87375529
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorService.java
@@ -0,0 +1,35 @@
+/*
+ * 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/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorServiceImpl.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorServiceImpl.java
new file mode 100644
index 0000000000..ae4ed12b7b
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/CalculatorServiceImpl.java
@@ -0,0 +1,70 @@
+/*
+ * 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.osoa.sca.annotations.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 setDivideService(DivideService divideService) {
+ this.divideService = divideService;
+ }
+
+ @Reference
+ public void setMultiplyService(MultiplyService multiplyService) {
+ this.multiplyService = multiplyService;
+ }
+
+ public double add(double n1, double n2) {
+ return addService.add(n1, n2);
+ }
+
+ public double subtract(double n1, double n2) {
+ return subtractService.subtract(n1, n2);
+ }
+
+ public double multiply(double n1, double n2) {
+ return multiplyService.multiply(n1, n2);
+ }
+
+ public double divide(double n1, double n2) {
+ return divideService.divide(n1, n2);
+ }
+
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideService.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideService.java
new file mode 100644
index 0000000000..ef6a8b375b
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideService.java
@@ -0,0 +1,28 @@
+/*
+ * 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/sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideServiceImpl.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideServiceImpl.java
new file mode 100644
index 0000000000..8c33862f6d
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/DivideServiceImpl.java
@@ -0,0 +1,30 @@
+/*
+ * 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/sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyService.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyService.java
new file mode 100644
index 0000000000..db568cc762
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyService.java
@@ -0,0 +1,28 @@
+/*
+ * 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/sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyServiceImpl.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyServiceImpl.java
new file mode 100644
index 0000000000..c7fbc73c00
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/MultiplyServiceImpl.java
@@ -0,0 +1,30 @@
+/*
+ * 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/sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractService.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractService.java
new file mode 100644
index 0000000000..56ee372fc4
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractService.java
@@ -0,0 +1,28 @@
+/*
+ * 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 SubtractService {
+
+ double subtract(double n1, double n2);
+
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractServiceImpl.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractServiceImpl.java
new file mode 100644
index 0000000000..1a7f145ad8
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/SubtractServiceImpl.java
@@ -0,0 +1,30 @@
+/*
+ * 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) {
+ return n1 - n2;
+ }
+
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/java/calculator/TestSvnProps.java b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/TestSvnProps.java
new file mode 100644
index 0000000000..bbcff7a98b
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/java/calculator/TestSvnProps.java
@@ -0,0 +1,27 @@
+/*
+ * 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;
+
+/**
+ * @version $Rev$ $Date$
+ */
+public class TestSvnProps {
+ //adding a change
+}
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/Calculator.composite b/sandbox/svkrish/integrated-calculator/src/main/resources/Calculator.composite
new file mode 100644
index 0000000000..ed58018c7f
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/Calculator.composite
@@ -0,0 +1,67 @@
+<?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"
+ name="Calculator">
+
+ <component name="CalculatorServiceComponent">
+ <implementation.java class="calculator.CalculatorServiceImpl"/>
+ <reference name="addService" target="AddServiceComponent" />
+ <reference name="subtractService" target="SubtractServiceComponent" />
+ <reference name="multiplyService" target="MultiplyServiceComponent" />
+ <reference name="divideService" target="DivideServiceComponent" />
+ </component>
+
+ <!--component name="AddServiceComponent">
+ <implementation.java class="calculator.AddServiceImpl"/>
+ </component>
+
+ <component name="SubtractServiceComponent">
+ <implementation.java class="calculator.SubtractServiceImpl"/>
+ </component>
+
+ <component name="MultiplyServiceComponent">
+ <implementation.java class="calculator.MultiplyServiceImpl"/>
+ </component>
+
+ <component name="DivideServiceComponent">
+ <implementation.java class="calculator.DivideServiceImpl"/>
+ </component-->
+
+
+ <component name="AddServiceComponent">
+ <implementation.script script="calculator/AddServiceImpl.js"/>
+ </component>
+
+ <component name="SubtractServiceComponent">
+ <implementation.script script="calculator/SubtractServiceImpl.rb"/>
+ </component>
+
+
+ <reference name="MultiplyRMIService" promote="CalculatorServiceComponent/multiplyService">
+ <binding.rmi host="localhost" port="8099" serviceName="CalculatorRMIService"/>
+ </reference>
+
+
+ <reference name="DivideWebService" promote="CalculatorServiceComponent/divideService">
+ <interface.java interface="calculator.CalculatorService" />
+ <binding.ws wsdlElement="http://calculator#wsdl.port(CalculatorService/CalculatorSoapPort)"/>
+ </reference>
+
+</composite>
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.componentType b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.componentType
new file mode 100644
index 0000000000..e3622aa868
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.componentType
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="ASCII"?>
+<!--
+ * 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.
+-->
+<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"
+ xmlns:wsdli="http://www.w3.org/2006/01/wsdl-instance"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <service name="HelloWorldService">
+ <interface.java interface="calculator.AddService" />
+ </service>
+
+</componentType>
+ \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.js b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.js
new file mode 100644
index 0000000000..6f11106ddd
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/AddServiceImpl.js
@@ -0,0 +1,22 @@
+/*
+ * 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.
+ */
+
+function add(n1, n2) {
+ return n1 + n2;
+} \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.componentType b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.componentType
new file mode 100644
index 0000000000..8ceb141963
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.componentType
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="ASCII"?>
+<!--
+ * 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.
+-->
+<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"
+ xmlns:wsdli="http://www.w3.org/2006/01/wsdl-instance"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <service name="HelloWorldService">
+ <interface.java interface="calculator.DivideService" />
+ </service>
+
+</componentType>
+ \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.groovy b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.groovy
new file mode 100644
index 0000000000..c31c1e8fd6
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/DivideServiceImpl.groovy
@@ -0,0 +1,22 @@
+/*
+ * 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.
+ */
+
+def divide(n1, n2) {
+ return n1 / n2
+} \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.componentType b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.componentType
new file mode 100644
index 0000000000..17727219cb
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.componentType
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="ASCII"?>
+<!--
+ * 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.
+-->
+<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"
+ xmlns:wsdli="http://www.w3.org/2006/01/wsdl-instance"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <service name="HelloWorldService">
+ <interface.java interface="calculator.MultiplyService" />
+ </service>
+
+</componentType>
+ \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.py b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.py
new file mode 100644
index 0000000000..cce0b5b3ec
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/MultiplyServiceImpl.py
@@ -0,0 +1,20 @@
+# 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.
+#
+
+def multiply(n1, n2):
+ return n1 * n2 \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.componentType b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.componentType
new file mode 100644
index 0000000000..a89e56bf7c
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.componentType
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="ASCII"?>
+<!--
+ * 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.
+-->
+<componentType xmlns="http://www.osoa.org/xmlns/sca/1.0"
+ xmlns:wsdli="http://www.w3.org/2006/01/wsdl-instance"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <service name="HelloWorldService">
+ <interface.java interface="calculator.SubtractService" />
+ </service>
+
+</componentType>
+ \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.rb b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.rb
new file mode 100644
index 0000000000..132a1d13b0
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/calculator/SubtractServiceImpl.rb
@@ -0,0 +1,21 @@
+# 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.
+#
+
+def subtract(n1, n2)
+ return n1 - n2
+end \ No newline at end of file
diff --git a/sandbox/svkrish/integrated-calculator/src/main/resources/wsdl/calculator.wsdl b/sandbox/svkrish/integrated-calculator/src/main/resources/wsdl/calculator.wsdl
new file mode 100644
index 0000000000..64e1aaa947
--- /dev/null
+++ b/sandbox/svkrish/integrated-calculator/src/main/resources/wsdl/calculator.wsdl
@@ -0,0 +1,87 @@
+<?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.
+-->
+<wsdl:definitions targetNamespace="http://calculator" xmlns:tns="http://calculator" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ name="calculator">
+
+ <wsdl:types>
+ <schema elementFormDefault="qualified" targetNamespace="http://calculator" xmlns="http://www.w3.org/2001/XMLSchema">
+ <!-- element name="value" type="double"/>
+ <element name="divide">
+ <complexType>
+ <sequence>
+ <element name="first" type="xsd:double"/>
+ <element name="second" type="xsd:double"/>
+ </sequence>
+ </complexType>
+ </element-->
+
+ <element name="divide">
+ <complexType>
+ <sequence>
+ <element name="first" type="xsd:double"/>
+ <element name="second" type="xsd:double"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="value">
+ <complexType>
+ <sequence>
+ <element name="result" type="xsd:double"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ </schema>
+ </wsdl:types>
+
+ <wsdl:message name="request">
+ <wsdl:part element="tns:divide" name="parameters"/>
+ </wsdl:message>
+ <wsdl:message name="response">
+ <wsdl:part element="tns:value" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:portType name="Calculator">
+ <wsdl:operation name="divide">
+ <wsdl:input message="tns:request" name="request"/>
+ <wsdl:output message="tns:response" name="response"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="CalculatorSoapBinding" type="tns:Calculator">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="divide">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="request">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="response">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:service name="CalculatorService">
+ <wsdl:port binding="tns:CalculatorSoapBinding" name="CalculatorSoapPort">
+ <wsdlsoap:address location="http://localhost:8080/CalculatorServiceComponent"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>