summaryrefslogtreecommitdiffstats
path: root/java/sca-contrib/modules/implementation-script-runtime/src
diff options
context:
space:
mode:
Diffstat (limited to 'java/sca-contrib/modules/implementation-script-runtime/src')
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/engines/TuscanyJRubyScriptEngine.java697
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProvider.java176
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProviderFactory.java55
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptInvoker.java84
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptPropertyFactory.java225
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/main/resources/META-INF/services/org.apache.tuscany.sca.provider.ImplementationProviderFactory19
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/AbstractSCATestCase.java60
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/AbstractHelloWorldTestCase.java38
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorld.java30
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorldProxy.java37
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/AbstractHelloWorldTestCase.java38
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorld.java30
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorldProxy.java37
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorldTestCase.java28
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorldTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReferenceTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/HelloWorldTarget.java34
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReferenceTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReferenceTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JythonReferenceTestCase.java29
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.componentType30
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.groovy22
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.js23
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.py20
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.rb21
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorld.composite33
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.componentType32
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.groovy22
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.js23
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.py20
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.rb21
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReference.composite38
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReference.composite38
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReference.composite38
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JythonReference.composite38
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.componentType31
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.groovy22
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.js22
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.py20
-rw-r--r--java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.rb21
53 files changed, 0 insertions, 2673 deletions
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/engines/TuscanyJRubyScriptEngine.java b/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/engines/TuscanyJRubyScriptEngine.java
deleted file mode 100644
index 324246c32b..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/engines/TuscanyJRubyScriptEngine.java
+++ /dev/null
@@ -1,697 +0,0 @@
-/*
-* Copyright (c) 2006, Sun Microsystems, Inc.
-* All rights reserved.
-*
-* Redistribution and use in source and binary forms, with or without
-* modification, are permitted provided that the following conditions are met:
-*
-* - Redistributions of source code must retain the above copyright notice, this
-* list of conditions and the following disclaimer.
-*
-* - Redistributions in binary form must reproduce the above copyright notice,
-* this list of conditions and the following disclaimer in the documentation
-* and/or other materials provided with the distribution.
-*
-* - Neither the name of the Sun Microsystems, Inc. nor the names of
-* contributors may be used to endorse or promote products derived from this
-* software without specific prior written permission.
-*
-* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
-* CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
-* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
-* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
-* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY
-* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
-* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
-* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
-* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
-* DAMAGE.
-*/
-package org.apache.tuscany.sca.implementation.script.engines;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.io.PrintStream;
-import java.io.Reader;
-import java.io.StringWriter;
-import java.io.UnsupportedEncodingException;
-import java.io.Writer;
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.nio.ByteBuffer;
-import java.nio.CharBuffer;
-import java.nio.charset.Charset;
-import java.nio.charset.CharsetDecoder;
-import java.nio.charset.CoderResult;
-import java.nio.charset.CodingErrorAction;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import javax.script.AbstractScriptEngine;
-import javax.script.Bindings;
-import javax.script.Compilable;
-import javax.script.CompiledScript;
-import javax.script.Invocable;
-import javax.script.ScriptContext;
-import javax.script.ScriptEngine;
-import javax.script.ScriptEngineFactory;
-import javax.script.ScriptException;
-import javax.script.SimpleBindings;
-
-import org.jruby.Ruby;
-import org.jruby.RubyException;
-import org.jruby.RubyIO;
-import org.jruby.RubyObject;
-import org.jruby.ast.Node;
-import org.jruby.exceptions.RaiseException;
-import org.jruby.internal.runtime.GlobalVariable;
-import org.jruby.internal.runtime.GlobalVariables;
-import org.jruby.internal.runtime.ReadonlyAccessor;
-import org.jruby.internal.runtime.ValueAccessor;
-import org.jruby.javasupport.Java;
-import org.jruby.javasupport.JavaEmbedUtils;
-import org.jruby.javasupport.JavaObject;
-import org.jruby.javasupport.JavaUtil;
-import org.jruby.runtime.Block;
-import org.jruby.runtime.IAccessor;
-import org.jruby.runtime.builtin.IRubyObject;
-import org.jruby.util.KCode;
-
-import com.sun.script.jruby.JRubyScriptEngineFactory;
-
-/**
- * This class is a copy of the class com.sun.script.ruby.JRubyScriptEngine with some minor modifications
- * to work around problems with Tuscany setting SCA properties and references as global variable in JRuby
- * Should only need it temporarily till a new BSF release fixes it.
- *
- * @version $Rev$ $Date$
- */
-@SuppressWarnings("unchecked")
-public class TuscanyJRubyScriptEngine extends AbstractScriptEngine
- implements Compilable, Invocable {
-
- // my factory, may be null
- private ScriptEngineFactory factory;
- private Ruby runtime;
-
- public TuscanyJRubyScriptEngine() {
- // Allow privileged access to ready properties. Requires PropertyPermission in security
- // policy.
- String rubyPath = AccessController.doPrivileged(new PrivilegedAction<String>() {
- public String run() {
- return System.getProperty("com.sun.script.jruby.loadpath");
- }
- });
- init(rubyPath);
- }
-
- public TuscanyJRubyScriptEngine(String loadPath) {
- init(loadPath);
- }
-
- // my implementation for CompiledScript
- private class JRubyCompiledScript extends CompiledScript {
- // my compiled code
- private Node node;
-
- JRubyCompiledScript (Node node) {
- this.node = node;
- }
-
- public ScriptEngine getEngine() {
- return TuscanyJRubyScriptEngine.this;
- }
-
- public Object eval(ScriptContext ctx) throws ScriptException {
- return evalNode(node, ctx);
- }
- }
-
- // Compilable methods
- public CompiledScript compile(String script)
- throws ScriptException {
- Node node = compileScript(script, context);
- return new JRubyCompiledScript(node);
- }
-
- public CompiledScript compile (Reader reader)
- throws ScriptException {
- Node node = compileScript(reader, context);
- return new JRubyCompiledScript(node);
- }
-
- // Invocable methods
- public Object invokeFunction(String name, Object... args)
- throws ScriptException, NoSuchMethodException {
- return invokeImpl(null, name, args, Object.class);
- }
-
- public Object invokeMethod(Object obj, String name, Object... args)
- throws ScriptException, NoSuchMethodException {
- if (obj == null) {
- throw new IllegalArgumentException("script object is null");
- }
- return invokeImpl(obj, name, args, Object.class);
- }
-
- public Object getInterface(Object obj, Class clazz) {
- if (obj == null) {
- throw new IllegalArgumentException("script object is null");
- }
- return makeInterface(obj, clazz);
- }
-
- public Object getInterface(Class clazz) {
- return makeInterface(null, clazz);
- }
-
- private <T> T makeInterface(Object obj, Class<T> clazz) {
- if (clazz == null || !clazz.isInterface()) {
- throw new IllegalArgumentException("interface Class expected");
- }
- final Object thiz = obj;
- return (T) Proxy.newProxyInstance(
- clazz.getClassLoader(),
- new Class[] { clazz },
- new InvocationHandler() {
- public Object invoke(Object proxy, Method m, Object[] args)
- throws Throwable {
- return invokeImpl(thiz, m.getName(),
- args, m.getReturnType());
- }
- });
- }
-
- // ScriptEngine methods
- public synchronized Object eval(String str, ScriptContext ctx)
- throws ScriptException {
- Node node = compileScript(str, ctx);
- return evalNode(node, ctx);
- }
-
- public synchronized Object eval(Reader reader, ScriptContext ctx)
- throws ScriptException {
- Node node = compileScript(reader, ctx);
- return evalNode(node, ctx);
- }
-
- public ScriptEngineFactory getFactory() {
- synchronized (this) {
- if (factory == null) {
- factory = new JRubyScriptEngineFactory();
- }
- }
- return factory;
- }
-
- public Bindings createBindings() {
- return new SimpleBindings();
- }
-
- // package-private methods
- void setFactory(ScriptEngineFactory factory) {
- this.factory = factory;
- }
-
- // internals only below this point
-
- private Object rubyToJava(IRubyObject value) {
- return rubyToJava(value, Object.class);
- }
-
- private Object rubyToJava(IRubyObject value, Class type) {
- return JavaUtil.convertArgument(
- runtime,
- Java.ruby_to_java(value, value, Block.NULL_BLOCK),
- type);
- }
-
- private IRubyObject javaToRuby(Object value) {
- if (value instanceof IRubyObject) {
- return (IRubyObject) value;
- }
- IRubyObject result = JavaUtil.convertJavaToRuby(runtime, value);
- if (result instanceof JavaObject) {
- return runtime.getModule("JavaUtilities").callMethod(runtime.getCurrentContext(), "wrap", result);
- }
- return result;
- }
-
- private synchronized Node compileScript(String script, ScriptContext ctx)
- throws ScriptException {
- GlobalVariables oldGlobals = runtime.getGlobalVariables();
- try {
- setErrorWriter(ctx.getErrorWriter());
- setGlobalVariables(ctx);
- String filename = (String) ctx.getAttribute(ScriptEngine.FILENAME);
- if (filename == null) {
- filename = "<unknown>";
- }
- return runtime.parseEval(script, filename, null, 0);
- } catch (RaiseException e) {
- RubyException re = e.getException();
- runtime.printError(re);
- throw new ScriptException(e);
- } catch (Exception e) {
- throw new ScriptException(e);
- } finally {
- if (oldGlobals != null) {
- setGlobalVariables(oldGlobals);
- }
- }
- }
-
- private synchronized Node compileScript(Reader reader, ScriptContext ctx)
- throws ScriptException {
- GlobalVariables oldGlobals = runtime.getGlobalVariables();
- try {
- setErrorWriter(ctx.getErrorWriter());
- setGlobalVariables(ctx);
- String filename = (String) ctx.getAttribute(ScriptEngine.FILENAME);
- if (filename == null) {
- filename = "<unknown>";
- String script = getRubyScript(reader);
- return runtime.parseEval(script, filename, null, 0);
- }
- InputStream inputStream = getRubyReader(filename);
- return runtime.parseFile(inputStream, filename, null);
- } catch (RaiseException e) {
- RubyException re = e.getException();
- runtime.printError(re);
- throw new ScriptException(e);
- } catch (Exception exp) {
- throw new ScriptException(exp);
- } finally {
- if (oldGlobals != null) {
- setGlobalVariables(oldGlobals);
- }
- }
- }
-
- private String getRubyScript(Reader reader) throws IOException {
- StringBuffer sb = new StringBuffer();
- char[] cbuf;
- while (true) {
- cbuf = new char[8*1024];
- int chars = reader.read(cbuf, 0, cbuf.length);
- if (chars < 0) {
- break;
- }
- sb.append(cbuf, 0, chars);
- }
- cbuf = null;
- return (new String(sb)).trim();
- }
-
- private InputStream getRubyReader(String filename) throws FileNotFoundException {
- File file = new File(filename);
- return new FileInputStream(file);
- }
-
- private void setGlobalVariables(final ScriptContext ctx) {
- ctx.setAttribute("context", ctx, ScriptContext.ENGINE_SCOPE);
- setGlobalVariables(new GlobalVariables(runtime) {
- GlobalVariables parent = runtime.getGlobalVariables();
-
- @Override
- public void define(String name, IAccessor accessor) {
- assert name != null;
- assert accessor != null;
- assert name.startsWith("$");
- synchronized (ctx) {
- Bindings engineScope = ctx.getBindings(ScriptContext.ENGINE_SCOPE);
- engineScope.put(name, new GlobalVariable(accessor));
- }
- }
-
- @Override
- public void defineReadonly(String name, IAccessor accessor) {
- assert name != null;
- assert accessor != null;
- assert name.startsWith("$");
- synchronized (ctx) {
- Bindings engineScope = ctx.getBindings(ScriptContext.ENGINE_SCOPE);
- engineScope.put(name, new GlobalVariable(new
- ReadonlyAccessor(name, accessor)));
- }
- }
-
- @Override
- public boolean isDefined(String name) {
- assert name != null;
- assert name.startsWith("$");
- synchronized (ctx) {
- String modifiedName = name.substring(1);
- boolean defined = ctx.getAttributesScope(modifiedName) != -1;
- return defined ? true : parent.isDefined(name);
- }
- }
-
- @Override
- public void alias(String name, String oldName) {
- assert name != null;
- assert oldName != null;
- assert name.startsWith("$");
- assert oldName.startsWith("$");
-
- if (runtime.getSafeLevel() >= 4) {
- throw runtime.newSecurityError("Insecure: can't alias global variable");
- }
-
- synchronized (ctx) {
- int scope = ctx.getAttributesScope(name);
- if (scope == -1) {
- scope = ScriptContext.ENGINE_SCOPE;
- }
-
- IRubyObject value = get(oldName);
- ctx.setAttribute(name, rubyToJava(value), scope);
- }
- }
-
- @Override
- public IRubyObject get(String name) {
- assert name != null;
- assert name.startsWith("$");
-
- synchronized (ctx) {
- // skip '$' and try
- String modifiedName = name.substring(1);
- int scope = ctx.getAttributesScope(modifiedName);
- if (scope == -1) {
- return parent.get(name);
- }
-
- Object obj = ctx.getAttribute(modifiedName, scope);
- if (obj instanceof IAccessor) {
- return ((IAccessor)obj).getValue();
- } else {
- return javaToRuby(obj);
- }
- }
- }
-
- @Override
- public IRubyObject set(String name, IRubyObject value) {
- assert name != null;
- assert name.startsWith("$");
-
- if (runtime.getSafeLevel() >= 4) {
- throw runtime.newSecurityError("Insecure: can't change global variable value");
- }
-
- synchronized (ctx) {
- // skip '$' and try
- String modifiedName = name.substring(1);
- int scope = ctx.getAttributesScope(modifiedName);
- if (scope == -1) {
- scope = ScriptContext.ENGINE_SCOPE;
- }
- IRubyObject oldValue = get(name);
- Object obj = ctx.getAttribute(modifiedName, scope);
- if (obj instanceof IAccessor) {
- ((IAccessor)obj).setValue(value);
- } else {
- ctx.setAttribute(modifiedName, rubyToJava(value), scope);
- if ("KCODE".equals(modifiedName)) {
- setKCode((String)rubyToJava(value));
- } else if ("stdout".equals(modifiedName)) {
- equalOutputs((RubyObject)value);
- }
- }
- return oldValue;
- }
- }
-
- @Override
- public Set<String> getNames() {
- HashSet set = new HashSet();
- synchronized (ctx) {
- for (Object scope : ctx.getScopes()) {
- Bindings b = ctx.getBindings((Integer)scope);
- if (b != null) {
- for (Object key: b.keySet()) {
- set.add(key);
- }
- }
- }
- }
- for (Iterator<String> names = parent.getNames().iterator(); names.hasNext();) {
- set.add(names.next());
- }
- return Collections.unmodifiableSet(set);
- }
-
- @Override
- public IRubyObject getDefaultSeparator() {
- return parent.getDefaultSeparator();
- }
- });
- }
-
- private void setGlobalVariables(GlobalVariables globals) {
- runtime.setGlobalVariables(globals);
- }
-
- private synchronized Object evalNode(Node node, ScriptContext ctx)
- throws ScriptException {
- GlobalVariables oldGlobals = runtime.getGlobalVariables();
- try {
- setWriterOutputStream(ctx.getWriter());
- setErrorWriter(ctx.getErrorWriter());
- setGlobalVariables(ctx);
- return rubyToJava(runtime.runNormally(node, false));
- } catch (Exception exp) {
- throw new ScriptException(exp);
- } finally {
- try {
- JavaEmbedUtils.terminate(runtime);
- } catch (RaiseException e) {
- RubyException re = e.getException();
- runtime.printError(re);
- if (!runtime.fastGetClass("SystemExit").isInstance(re)) {
- throw new ScriptException(e);
- }
- } finally {
- if (oldGlobals != null) {
- setGlobalVariables(oldGlobals);
- }
- }
- }
- }
-
- private void init(final String loadPath) {
- AccessController.doPrivileged(new PrivilegedAction<Object>() {
- public Object run() {
- runtime = Ruby.newInstance();
- IAccessor d = new ValueAccessor(runtime.newString("<script>"));
- runtime.getGlobalVariables().define("$PROGRAM_NAME", d);
- runtime.getGlobalVariables().define("$0", d);
- String path = loadPath;
- if (path == null) {
- path = System.getProperty("java.class.path");
- }
- List list = Arrays.asList(path.split(File.pathSeparator));
- runtime.getLoadService().init(list);
- runtime.getLoadService().require("java");
- return null;
- }
- });
- }
-
- private synchronized Object invokeImpl(final Object obj, String method,
- Object[] args, Class returnType)
- throws ScriptException {
- if (method == null) {
- throw new NullPointerException("method name is null");
- }
- GlobalVariables oldGlobals = runtime.getGlobalVariables();
- try {
- setWriterOutputStream(context.getWriter());
- setErrorWriter(context.getErrorWriter());
- setGlobalVariables(context);
- IRubyObject rubyRecv = obj != null ?
- JavaUtil.convertJavaToRuby(runtime, obj) : runtime.getTopSelf();
-
- IRubyObject result;
- if (args != null && args.length > 0) {
- IRubyObject[] rubyArgs = JavaUtil.convertJavaArrayToRuby(runtime, args);
- // Create Ruby proxies for any input arguments that are not primitives.
- IRubyObject javaUtilities = runtime.getObject().getConstant("JavaUtilities");
- for (int i = 0; i < rubyArgs.length; i++) {
- IRubyObject tmp = rubyArgs[i];
- if (tmp instanceof JavaObject) {
- rubyArgs[i] = javaUtilities.callMethod(runtime.getCurrentContext(), "wrap", tmp);
- }
- }
- result = rubyRecv.callMethod(runtime.getCurrentContext(), method, rubyArgs);
- } else {
- result = rubyRecv.callMethod(runtime.getCurrentContext(), method);
- }
- return rubyToJava(result, returnType);
- } catch (Exception exp) {
- throw new ScriptException(exp);
- } finally {
- try {
- JavaEmbedUtils.terminate(runtime);
- } catch (RaiseException e) {
- RubyException re = e.getException();
- runtime.printError(re);
- if (!runtime.fastGetClass("SystemExit").isInstance(re)) {
- throw new ScriptException(e);
- }
- } finally {
- if (oldGlobals != null) {
- setGlobalVariables(oldGlobals);
- }
- }
- }
- }
-
- private void setKCode(String encoding) {
- KCode kcode = KCode.create(runtime, encoding);
- runtime.setKCode(kcode);
- }
-
- private void equalOutputs(RubyObject value) {
- runtime.getGlobalVariables().set("$>", value);
- runtime.getGlobalVariables().set("$defout", value);
- }
-
- private void setWriterOutputStream(Writer writer) {
- try {
- RubyIO dummy_io =
- new RubyIO(runtime, new PrintStream(new WriterOutputStream(new StringWriter())));
- runtime.getGlobalVariables().set("$stderr", dummy_io); //discard unwanted warnings
- RubyIO io =
- new RubyIO(runtime, new PrintStream(new WriterOutputStream(writer)));
- io.getOpenFile().getMainStream().setSync(true);
- runtime.defineGlobalConstant("STDOUT", io);
- runtime.getGlobalVariables().set("$>", io);
- runtime.getGlobalVariables().set("$stdout", io);
- runtime.getGlobalVariables().set("$defout", io);
- } catch (UnsupportedEncodingException exp) {
- throw new IllegalArgumentException(exp);
- }
- }
-
- private void setErrorWriter(Writer writer) {
- try {
- RubyIO dummy_io =
- new RubyIO(runtime, new PrintStream(new WriterOutputStream(new StringWriter())));
- runtime.getGlobalVariables().set("$stderr", dummy_io); //discard unwanted warnings
- RubyIO io =
- new RubyIO(runtime, new PrintStream(new WriterOutputStream(writer)));
- io.getOpenFile().getMainStream().setSync(true);
- runtime.defineGlobalConstant("STDERR", io);
- runtime.getGlobalVariables().set("$stderr", io);
- runtime.getGlobalVariables().set("$deferr", io);
- } catch (UnsupportedEncodingException exp) {
- throw new IllegalArgumentException(exp);
- }
- }
-
- private String getEncoding() {
- String enc = System.getProperty("sun.jnu.encoding");
- if (enc != null) {
- return enc;
- }
- return ((enc = System.getProperty("file.encoding")) == null) ? "UTF-8" : enc;
- }
-
- private class WriterOutputStream extends OutputStream {
-
- private Writer writer;
- private CharsetDecoder decoder;
-
- private WriterOutputStream(Writer writer) throws UnsupportedEncodingException {
- this(writer, getEncoding());
- }
-
- private WriterOutputStream(Writer writer, String enc) throws UnsupportedEncodingException {
- this.writer = writer;
- if (enc == null) {
- throw new UnsupportedEncodingException("encoding is " + enc);
- }
- try {
- decoder = Charset.forName(enc).newDecoder();
- } catch (Exception e) {
- throw new UnsupportedEncodingException("Unsupported: " + enc);
- }
- decoder.onMalformedInput(CodingErrorAction.REPLACE);
- decoder.onUnmappableCharacter(CodingErrorAction.REPLACE);
- }
-
- @Override
- public void close() throws IOException {
- synchronized(writer) {
- decoder = null;
- writer.close();
- }
- }
-
- @Override
- public void flush() throws IOException {
- synchronized(writer) {
- writer.flush();
- }
- }
-
- @Override
- public void write(int b) throws IOException {
- byte[] buffer = new byte[1];
- write(buffer, 0, 1);
- }
-
- @Override
- public void write(byte[] buffer) throws IOException {
- write(buffer, 0, buffer.length);
- }
-
- @Override
- public void write(byte[] buffer, int offset, int length) throws IOException {
- synchronized(writer) {
- if (offset < 0 || offset > buffer.length - length || length < 0) {
- throw new IndexOutOfBoundsException();
- }
- if (length == 0) {
- return;
- }
- ByteBuffer bytes = ByteBuffer.wrap(buffer, offset, length);
- CharBuffer chars = CharBuffer.allocate(length);
- convert(bytes, chars);
- char[] cbuf = new char[chars.length()];
- chars.get(cbuf, 0, chars.length());
- writer.write(cbuf);
- writer.flush();
- }
- }
-
- private void convert(ByteBuffer bytes, CharBuffer chars) throws IOException {
- decoder.reset();
- chars.clear();
- CoderResult result = decoder.decode(bytes, chars, true);
- if (result.isError() || result.isOverflow()) {
- throw new IOException(result.toString());
- } else if (result.isUnderflow()) {
- chars.flip();
- }
- }
- }
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProvider.java b/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProvider.java
deleted file mode 100644
index 473b990a79..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProvider.java
+++ /dev/null
@@ -1,176 +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 org.apache.tuscany.sca.implementation.script.provider;
-
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.net.URL;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import javax.script.Invocable;
-import javax.script.ScriptEngine;
-import javax.script.ScriptEngineManager;
-import javax.script.ScriptException;
-
-import org.apache.axiom.om.OMElement;
-import org.apache.bsf.xml.XMLHelper;
-import org.apache.tuscany.sca.assembly.ComponentReference;
-import org.apache.tuscany.sca.assembly.Property;
-import org.apache.tuscany.sca.assembly.Reference;
-import org.apache.tuscany.sca.assembly.Service;
-import org.apache.tuscany.sca.core.factory.ObjectCreationException;
-import org.apache.tuscany.sca.core.factory.ObjectFactory;
-import org.apache.tuscany.sca.implementation.script.ScriptImplementation;
-import org.apache.tuscany.sca.implementation.script.engines.TuscanyJRubyScriptEngine;
-import org.apache.tuscany.sca.interfacedef.InterfaceContract;
-import org.apache.tuscany.sca.interfacedef.Operation;
-import org.apache.tuscany.sca.interfacedef.java.JavaInterface;
-import org.apache.tuscany.sca.interfacedef.wsdl.WSDLInterfaceContract;
-import org.apache.tuscany.sca.invocation.Invoker;
-import org.apache.tuscany.sca.provider.ImplementationProvider;
-import org.apache.tuscany.sca.runtime.RuntimeComponent;
-import org.apache.tuscany.sca.runtime.RuntimeComponentService;
-
-/**
- * An ImplementationProvider for Script implementations.
- *
- * @version $Rev: $ $Date: $
- */
-public class ScriptImplementationProvider implements ImplementationProvider {
-
- private RuntimeComponent component;
- private ScriptImplementation implementation;
- private ScriptPropertyFactory propertyFactory;
- private ScriptEngine scriptEngine;
- private XMLHelper xmlHelper;
-
- public ScriptImplementationProvider(RuntimeComponent component, ScriptImplementation implementation, ScriptPropertyFactory propertyFactory) {
- this.component = component;
- this.implementation = implementation;
- this.propertyFactory = propertyFactory;
-
- // Set the databinding and XMLHelper for WSDL interfaces
- for (Service service : component.getServices()) {
- InterfaceContract ic = service.getInterfaceContract();
- if (ic instanceof WSDLInterfaceContract) {
- ic.getInterface().resetDataBinding(OMElement.class.getName());
- xmlHelper = XMLHelper.getArgHelper(scriptEngine);
- }
- }
- }
-
- public void start() {
- try {
- String language = implementation.getLanguage();
- if (language == null) {
- language = implementation.getScript();
- language = language.substring(language.lastIndexOf('.') +1);
- }
- scriptEngine = scriptEngine(language);
- if (scriptEngine == null) {
- throw new ObjectCreationException("no script engine found for language: " + implementation.getLanguage());
- }
- if (!(scriptEngine instanceof Invocable)) {
- throw new ObjectCreationException("script engine does not support Invocable: " + scriptEngine);
- }
-
- for (Reference reference : implementation.getReferences()) {
- scriptEngine.put(reference.getName(), getProxy(reference.getName()));
- }
-
- for (Property property : implementation.getProperties()) {
- ObjectFactory<?> valueFactory = propertyFactory.createValueFactory(property);
- if (valueFactory != null) {
- scriptEngine.put(property.getName(), valueFactory.getInstance());
- }
- }
-
- URL url = new URL(implementation.getLocation());
- InputStreamReader reader = new InputStreamReader(url.openStream());
- scriptEngine.eval(reader);
- reader.close();
-
- } catch (IOException e) {
- throw new IllegalArgumentException(e);
- } catch (ScriptException e) {
- throw new IllegalArgumentException(e);
- }
- }
-
- public void stop() {
- }
-
- public boolean supportsOneWayInvocation() {
- return false;
- }
-
- public Invoker createInvoker(RuntimeComponentService service, Operation operation) {
- return new ScriptInvoker(scriptEngine, xmlHelper, operation);
- }
-
- private Object getProxy(String name) {
- for (ComponentReference reference : component.getReferences()) {
- if (reference.getName().equals(name)) {
- Class<?> iface = ((JavaInterface)reference.getInterfaceContract().getInterface()).getJavaClass();
- return component.getComponentContext().getService(iface, name);
- }
- }
- throw new IllegalArgumentException("reference " + name + " not found on component: " + component);
- }
-
- /**
- * Returns the script engine for the given language.
- *
- * @param language
- * @return
- */
- private ScriptEngine scriptEngine(String language) {
- if ("rb".equals(language)) {
-
- // Hack for now to work around a problem with the JRuby script engine
- return new TuscanyJRubyScriptEngine();
- } else {
- if ("py".equals(language)) {
- pythonCachedir();
- }
-
- // Allow privileged access to run access classes. Requires RuntimePermission
- // for accessClassInPackage.sun.misc.
- ScriptEngineManager scriptEngineManager =
- AccessController.doPrivileged(new PrivilegedAction<ScriptEngineManager>() {
- public ScriptEngineManager run() {
- return new ScriptEngineManager();
- }
- });
- return scriptEngineManager.getEngineByExtension(language);
- }
- }
-
- /**
- * If the Python home isn't set then let Tuscany suppress messages other than errors
- * See TUSCANY-1950
- */
- private static void pythonCachedir() {
- if (System.getProperty("python.home") == null) {
- System.setProperty("python.verbose", "error");
- }
- }
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProviderFactory.java b/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProviderFactory.java
deleted file mode 100644
index f65403c9ed..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptImplementationProviderFactory.java
+++ /dev/null
@@ -1,55 +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 org.apache.tuscany.sca.implementation.script.provider;
-
-import org.apache.tuscany.sca.core.ExtensionPointRegistry;
-import org.apache.tuscany.sca.databinding.DataBindingExtensionPoint;
-import org.apache.tuscany.sca.databinding.Mediator;
-import org.apache.tuscany.sca.databinding.TransformerExtensionPoint;
-import org.apache.tuscany.sca.databinding.impl.MediatorImpl;
-import org.apache.tuscany.sca.implementation.script.ScriptImplementation;
-import org.apache.tuscany.sca.provider.ImplementationProvider;
-import org.apache.tuscany.sca.provider.ImplementationProviderFactory;
-import org.apache.tuscany.sca.runtime.RuntimeComponent;
-
-/**
- * An ImplementationProviderFactory for Script implementations.
- *
- * @version $Rev: $ $Date: $
- */
-public class ScriptImplementationProviderFactory implements ImplementationProviderFactory<ScriptImplementation> {
-
- private ScriptPropertyFactory propertyFactory;
-
- public ScriptImplementationProviderFactory(ExtensionPointRegistry extensionPoints) {
- Mediator mediator = new MediatorImpl(extensionPoints.getExtensionPoint(DataBindingExtensionPoint.class),
- extensionPoints.getExtensionPoint(TransformerExtensionPoint.class));
- propertyFactory = new ScriptPropertyFactory(mediator);
- }
-
- public ImplementationProvider createImplementationProvider(RuntimeComponent component, ScriptImplementation Implementation) {
- return new ScriptImplementationProvider(component, Implementation, propertyFactory);
- }
-
- public Class<ScriptImplementation> getModelType() {
- return ScriptImplementation.class;
- }
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptInvoker.java b/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptInvoker.java
deleted file mode 100644
index 976eb2c0dd..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptInvoker.java
+++ /dev/null
@@ -1,84 +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 org.apache.tuscany.sca.implementation.script.provider;
-
-import javax.script.Invocable;
-import javax.script.ScriptEngine;
-import javax.script.ScriptException;
-
-import org.apache.axiom.om.OMElement;
-import org.apache.bsf.xml.XMLHelper;
-import org.apache.tuscany.sca.interfacedef.Operation;
-import org.apache.tuscany.sca.invocation.Invoker;
-import org.apache.tuscany.sca.invocation.Message;
-
-/**
- * Perform the actual script invocation
- *
- * @version $Rev$ $Date$
- */
-public class ScriptInvoker implements Invoker {
-
- private ScriptEngine scriptEngine;
- private XMLHelper xmlHelper;
- private Operation operation;
-
- public ScriptInvoker(ScriptEngine scriptEngine, XMLHelper xmlHelper, Operation operation) {
- this.scriptEngine = scriptEngine;
- this.xmlHelper = xmlHelper;
- this.operation = operation;
- }
-
- private Object doInvoke(Object[] objects, Operation op) throws ScriptException {
- if (xmlHelper != null) {
- objects[0] = xmlHelper.toScriptXML((OMElement)objects[0]);
- }
-
- Operation oper = operation; // static setting
- if (oper.getName() == null) { // if no static setting
- oper = op; // use dynamic setting
- }
- Object response;
- try {
- response = ((Invocable)scriptEngine).invokeFunction(oper.getName(), objects);
- } catch (ScriptException e) {
- throw e;
- } catch (Exception e) {
- throw new ScriptException(e);
- }
-
- if (xmlHelper != null) {
- response = xmlHelper.toOMElement(response);
- }
-
- return response;
- }
-
- public Message invoke(Message msg) {
- try {
- Object resp = doInvoke((Object[])msg.getBody(), msg.getOperation());
- msg.setBody(resp);
- } catch (ScriptException e) {
- msg.setFaultBody(e.getCause());
- }
- return msg;
- }
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptPropertyFactory.java b/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptPropertyFactory.java
deleted file mode 100644
index 5833c9f4d5..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/main/java/org/apache/tuscany/sca/implementation/script/provider/ScriptPropertyFactory.java
+++ /dev/null
@@ -1,225 +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 org.apache.tuscany.sca.implementation.script.provider;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.StringTokenizer;
-
-import org.apache.tuscany.sca.assembly.Property;
-import org.apache.tuscany.sca.core.factory.ObjectCreationException;
-import org.apache.tuscany.sca.core.factory.ObjectFactory;
-import org.apache.tuscany.sca.databinding.Mediator;
-import org.apache.tuscany.sca.databinding.SimpleTypeMapper;
-import org.apache.tuscany.sca.databinding.impl.SimpleTypeMapperImpl;
-import org.apache.tuscany.sca.interfacedef.DataType;
-import org.apache.tuscany.sca.interfacedef.util.XMLType;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * A property factory for script properties.
- *
- * @version $Rev$ $Date$
- */
-public class ScriptPropertyFactory {
- private Mediator mediator = null;
- boolean isSimpleType;
-
- public ScriptPropertyFactory(Mediator mediator) {
- this.mediator = mediator;
- }
-
- public ObjectFactory createValueFactory(Property property) {
- isSimpleType = isSimpleType(property);
- Document doc = (Document)property.getValue();
- Element rootElement = doc.getDocumentElement();
-
- //FIXME : since scripts use dynamic types we need to generate a dynamic java type using the
- //XML structure of the property value. Should this be done in the JavaBeansDataBinding...
- Class javaType = null;
-
- if (property.isMany()) {
- if (isSimpleType) {
- String value = "";
- if (rootElement.getChildNodes().getLength() > 0) {
- value = rootElement.getChildNodes().item(0).getTextContent();
- }
- List<String> values =
- getSimplePropertyValues(value, javaType);
- return new ListObjectFactoryImpl(property,
- values,
- isSimpleType,
- javaType);
- } else {
- return new ListObjectFactoryImpl(property,
- getComplexPropertyValues(doc),
- isSimpleType,
- javaType);
- }
- } else {
- if (isSimpleType) {
- String value = "";
- if (rootElement.getChildNodes().getLength() > 0) {
- value = rootElement.getChildNodes().item(0).getTextContent();
- }
- return new ObjectFactoryImpl(property,
- value,
- isSimpleType,
- javaType);
- } else {
- Object value = getComplexPropertyValues(doc).get(0);
- return new ObjectFactoryImpl(property,
- value,
- isSimpleType,
- javaType);
- }
-
- }
- }
-
- private boolean isSimpleType(Property property) {
- if (property.getXSDType() != null) {
- return SimpleTypeMapperImpl.isSimpleXSDType(property.getXSDType());
- } else {
- if (property instanceof Document) {
- Document doc = (Document)property;
- Element element = doc.getDocumentElement();
- if (element.getChildNodes().getLength() == 1 &&
- element.getChildNodes().item(0).getNodeType() == Node.TEXT_NODE) {
- return true;
- }
- }
- }
- return false;
- }
-
- private List<String> getSimplePropertyValues(String concatenatedValue, Class<?> javaType) {
- List<String> propValues = new ArrayList<String>();
- StringTokenizer st = null;
- if ( javaType.getName().equals("java.lang.String")) {
- st = new StringTokenizer(concatenatedValue, "\"");
- } else {
- st = new StringTokenizer(concatenatedValue);
- }
- String aToken = null;
- while (st.hasMoreTokens()) {
- aToken = st.nextToken();
- if (aToken.trim().length() > 0) {
- propValues.add(aToken);
- }
- }
- return propValues;
- }
-
- private List<Node> getComplexPropertyValues(Document document) {
- Element rootElement = document.getDocumentElement();
- List<Node> propValues = new ArrayList<Node>();
- for (int count = 0 ; count < rootElement.getChildNodes().getLength() ; ++count) {
- if (rootElement.getChildNodes().item(count).getNodeType() == Node.ELEMENT_NODE) {
- propValues.add(rootElement.getChildNodes().item(count));
- }
- }
- return propValues;
- }
-
- public abstract class ObjectFactoryImplBase implements ObjectFactory {
- protected SimpleTypeMapper simpleTypeMapper = new SimpleTypeMapperImpl();
- protected Property property;
- protected Object propertyValue;
- protected Class<?> javaType;
- protected DataType<XMLType> sourceDataType;
- protected DataType<?> targetDataType;
- boolean isSimpleType;
-
- public ObjectFactoryImplBase(Property property, Object propertyValue, boolean isSimpleType, Class<?> javaType) {
-
- this.isSimpleType = isSimpleType;
- this.property = property;
- this.propertyValue = propertyValue;
- this.javaType = javaType;
-
- //FIXME : fix this when we have managed to generate dynamic java types
-
- /*sourceDataType =
- new DataTypeImpl<XMLType>(DOMDataBinding.NAME, Node.class,
- new XMLType(null, this.property.getXSDType()));
- TypeInfo typeInfo = null;
- if (this.property.getXSDType() != null) {
- if (SimpleTypeMapperExtension.isSimpleXSDType(this.property.getXSDType())) {
- typeInfo = new TypeInfo(property.getXSDType(), true, null);
- } else {
- typeInfo = new TypeInfo(property.getXSDType(), false, null);
- }
- } else {
- typeInfo = new TypeInfo(property.getXSDType(), false, null);
- }
-
- XMLType xmlType = new XMLType(typeInfo);
- String dataBinding = null; //(String)property.getExtensions().get(DataBinding.class.getName());
- if (dataBinding != null) {
- targetDataType = new DataTypeImpl<XMLType>(dataBinding, javaType, xmlType);
- } else {
- targetDataType = new DataTypeImpl<XMLType>(dataBinding, javaType, xmlType);
- mediator.getDataBindingRegistry().introspectType(targetDataType, null);
- }*/
- }
- }
-
- public class ObjectFactoryImpl extends ObjectFactoryImplBase {
- public ObjectFactoryImpl(Property property, Object propertyValue, boolean isSimpleType, Class<?> javaType) {
- super(property, propertyValue, isSimpleType, javaType);
- }
-
- public Object getInstance() throws ObjectCreationException {
- if (isSimpleType) {
- return simpleTypeMapper.toJavaObject(property.getXSDType(), (String)propertyValue, null);
- } else {
- return mediator.mediate(propertyValue, sourceDataType, targetDataType, null);
- }
- }
- }
-
- public class ListObjectFactoryImpl extends ObjectFactoryImplBase {
- public ListObjectFactoryImpl(Property property, List<?>propertyValues, boolean isSimpleType, Class<?> javaType) {
- super(property, propertyValues, isSimpleType, javaType);
- }
-
- public List<?> getInstance() throws ObjectCreationException {
- if (isSimpleType) {
- List<Object> values = new ArrayList<Object>();
- for (String aValue : (List<String>)propertyValue) {
- values.add(simpleTypeMapper.toJavaObject(property.getXSDType(), aValue, null));
- }
- return values;
- } else {
- List<Object> instances = new ArrayList<Object>();
- for (Node aValue : (List<Node>)propertyValue) {
- instances.add(mediator.mediate(aValue,
- sourceDataType,
- targetDataType,
- null));
- }
- return instances;
- }
- }
- }
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/main/resources/META-INF/services/org.apache.tuscany.sca.provider.ImplementationProviderFactory b/java/sca-contrib/modules/implementation-script-runtime/src/main/resources/META-INF/services/org.apache.tuscany.sca.provider.ImplementationProviderFactory
deleted file mode 100644
index 941cfd7fd5..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/main/resources/META-INF/services/org.apache.tuscany.sca.provider.ImplementationProviderFactory
+++ /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 implementation extension
-org.apache.tuscany.sca.implementation.script.provider.ScriptImplementationProviderFactory;model=org.apache.tuscany.sca.implementation.script.ScriptImplementation
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/AbstractSCATestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/AbstractSCATestCase.java
deleted file mode 100644
index f098885741..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/AbstractSCATestCase.java
+++ /dev/null
@@ -1,60 +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 org.apache.tuscany.sca.implementation.script.itests;
-
-import junit.framework.TestCase;
-
-import org.apache.tuscany.sca.node.Contribution;
-import org.apache.tuscany.sca.node.ContributionLocationHelper;
-import org.apache.tuscany.sca.node.Node;
-import org.apache.tuscany.sca.node.NodeFactory;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public abstract class AbstractSCATestCase<T> extends TestCase {
-
- protected Node node;
- protected T service;
-
- @Override
- @SuppressWarnings("unchecked")
- protected void setUp() throws Exception {
- String contribution = ContributionLocationHelper.getContributionLocation(getClass());
- node = NodeFactory.newInstance().createNode(getCompositeName(), new Contribution("test", contribution));
- node.start();
- service = (T) node.getService(getServiceClass(), "ClientComponent");
- }
-
- protected abstract Class getServiceClass();
-
- @Override
- protected void tearDown() throws Exception {
- node.stop();
- node.destroy();
- }
-
- protected String getCompositeName() {
- String className = this.getClass().getName();
- return className.substring(0, className.length() - 8).replace('.', '/') + ".composite";
- }
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/AbstractHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/AbstractHelloWorldTestCase.java
deleted file mode 100644
index 1af3a295a4..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/AbstractHelloWorldTestCase.java
+++ /dev/null
@@ -1,38 +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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-import org.apache.tuscany.sca.implementation.script.itests.AbstractSCATestCase;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public abstract class AbstractHelloWorldTestCase extends AbstractSCATestCase<HelloWorld> {
-
- public void testCalculator() throws Exception {
- assertEquals("Hello petra", service.sayHello("petra"));
- }
-
- @Override
- protected Class<HelloWorld> getServiceClass() {
- return HelloWorld.class;
- }
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorldTestCase.java
deleted file mode 100644
index 6a4f10dbbb..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class GroovyHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorld.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorld.java
deleted file mode 100644
index f87cf104f3..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorld.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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public interface HelloWorld {
-
- String sayHello(String s);
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorldProxy.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorldProxy.java
deleted file mode 100644
index cffe65c27a..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/HelloWorldProxy.java
+++ /dev/null
@@ -1,37 +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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-import org.oasisopen.sca.annotation.Reference;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class HelloWorldProxy implements HelloWorld {
-
- @Reference
- public HelloWorld delegate;
-
- public String sayHello(String s) {
- return delegate.sayHello(s);
- }
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorldTestCase.java
deleted file mode 100644
index ca4bd5ae6a..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JRubyHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorldTestCase.java
deleted file mode 100644
index 46ed9abce6..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JavaScriptHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorldTestCase.java
deleted file mode 100644
index d694515829..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.helloworld;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JythonHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/AbstractHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/AbstractHelloWorldTestCase.java
deleted file mode 100644
index e7375253a3..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/AbstractHelloWorldTestCase.java
+++ /dev/null
@@ -1,38 +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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-import org.apache.tuscany.sca.implementation.script.itests.AbstractSCATestCase;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public abstract class AbstractHelloWorldTestCase extends AbstractSCATestCase<HelloWorld> {
-
- public void testCalculator() throws Exception {
- // assertEquals("Hello petra from Tuscany", service.sayHello("petra"));
- }
-
- @Override
- protected Class<HelloWorld> getServiceClass() {
- return HelloWorld.class;
- }
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorldTestCase.java
deleted file mode 100644
index f93edc76d1..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class GroovyHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorld.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorld.java
deleted file mode 100644
index 910d22ec83..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorld.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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public interface HelloWorld {
-
- String sayHello(String s);
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorldProxy.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorldProxy.java
deleted file mode 100644
index 719212e831..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/HelloWorldProxy.java
+++ /dev/null
@@ -1,37 +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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-import org.oasisopen.sca.annotation.Reference;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class HelloWorldProxy implements HelloWorld {
-
- @Reference
- public HelloWorld delegate;
-
- public String sayHello(String s) {
- return delegate.sayHello(s);
- }
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorldTestCase.java
deleted file mode 100644
index 60c73359c0..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorldTestCase.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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JRubyHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorldTestCase.java
deleted file mode 100644
index cde96b4b9b..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JavaScriptHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorldTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorldTestCase.java
deleted file mode 100644
index 0e6be74e09..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorldTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.properties;
-
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JythonHelloWorldTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReferenceTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReferenceTestCase.java
deleted file mode 100644
index 6116581356..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReferenceTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.references;
-
-import org.apache.tuscany.sca.implementation.script.itests.helloworld.AbstractHelloWorldTestCase;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class GroovyReferenceTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/HelloWorldTarget.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/HelloWorldTarget.java
deleted file mode 100644
index dfcd37c46c..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/HelloWorldTarget.java
+++ /dev/null
@@ -1,34 +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 org.apache.tuscany.sca.implementation.script.itests.references;
-
-import org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorld;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class HelloWorldTarget implements HelloWorld {
-
- public String sayHello(String s) {
- return "Hello " + s;
- }
-
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReferenceTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReferenceTestCase.java
deleted file mode 100644
index 83c2e99469..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReferenceTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.references;
-
-import org.apache.tuscany.sca.implementation.script.itests.helloworld.AbstractHelloWorldTestCase;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JRubyReferenceTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReferenceTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReferenceTestCase.java
deleted file mode 100644
index 392e16411c..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReferenceTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.references;
-
-import org.apache.tuscany.sca.implementation.script.itests.helloworld.AbstractHelloWorldTestCase;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JavaScriptReferenceTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JythonReferenceTestCase.java b/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JythonReferenceTestCase.java
deleted file mode 100644
index 8866ae6b70..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/java/org/apache/tuscany/sca/implementation/script/itests/references/JythonReferenceTestCase.java
+++ /dev/null
@@ -1,29 +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 org.apache.tuscany.sca.implementation.script.itests.references;
-
-import org.apache.tuscany.sca.implementation.script.itests.helloworld.AbstractHelloWorldTestCase;
-
-/**
- *
- * @version $Rev$ $Date$
- */
-public class JythonReferenceTestCase extends AbstractHelloWorldTestCase {
- // super class does it all getting composite based on this class name
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorld.composite
deleted file mode 100644
index ce377e4ed3..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/GroovyHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="GroovyHelloWorld">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.groovy"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorld.composite
deleted file mode 100644
index 4d32ed9f6b..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JRubyHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JRubyHelloWorld">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.rb"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorld.composite
deleted file mode 100644
index 13cb94d511..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JavaScriptHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JavaScriptHelloWorld">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.js"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorld.composite
deleted file mode 100644
index c641b82cd6..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/JythonHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JythonHelloWorld">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.py"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.componentType b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.componentType
deleted file mode 100644
index bb0ddd002f..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.componentType
+++ /dev/null
@@ -1,30 +0,0 @@
-<?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="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorld" />
- </service>
-
-</componentType>
- \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.groovy b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.groovy
deleted file mode 100644
index 9f89bd373e..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.groovy
+++ /dev/null
@@ -1,22 +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.
- */
-
-def sayHello(s) {
- return "Hello " + s
-} \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.js b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.js
deleted file mode 100644
index eac2ab283f..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.js
+++ /dev/null
@@ -1,23 +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.
- */
-
-function sayHello(s) {
-
- return "Hello " + s;
-} \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.py b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.py
deleted file mode 100644
index f5dd0f8fcf..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.py
+++ /dev/null
@@ -1,20 +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.
-#
-
-def sayHello(s):
- return 'Hello ' + s \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.rb b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.rb
deleted file mode 100644
index cd2d3bcaea..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/helloworld/helloworld.rb
+++ /dev/null
@@ -1,21 +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.
-#
-
-def sayHello(s)
- return "Hello " + s
-end \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorld.composite
deleted file mode 100644
index 26574c6266..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/GroovyHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="GroovyProperties">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.properties.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.groovy"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorld.composite
deleted file mode 100644
index a3551cefc3..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JRubyHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JRubyProperties">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.properties.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent" />
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.rb"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorld.composite
deleted file mode 100644
index f72c6e922f..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JavaScriptHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JavaScriptProperties">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.properties.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.js"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorld.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorld.composite
deleted file mode 100644
index bd754c8d2e..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/JythonHelloWorld.composite
+++ /dev/null
@@ -1,33 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JythonProperties">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.properties.HelloWorldProxy"/>
- <reference name="delegate" target="HelloWorldComponent"></reference>
- </component>
-
- <component name="HelloWorldComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.py"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.componentType b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.componentType
deleted file mode 100644
index 06f261015e..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.componentType
+++ /dev/null
@@ -1,32 +0,0 @@
-<?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="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorld" />
- </service>
-
- <property name="greeter" type="xsd:string">Tuscany</property>
-
-</componentType>
- \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.groovy b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.groovy
deleted file mode 100644
index a7eb446d37..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.groovy
+++ /dev/null
@@ -1,22 +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.
- */
-
-def sayHello(s) {
- return "Hello " + s + " from " + greeter
-} \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.js b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.js
deleted file mode 100644
index 64df3ebbef..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.js
+++ /dev/null
@@ -1,23 +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.
- */
-
-function sayHello(s) {
-
- return "Hello " + s + " from " + greeter;
-} \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.py b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.py
deleted file mode 100644
index 868cfa9eeb..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.py
+++ /dev/null
@@ -1,20 +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.
-#
-
-def sayHello(s):
- return 'Hello ' + s + ' from ' + greeter \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.rb b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.rb
deleted file mode 100644
index 2844f8b8d9..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/properties/helloworld.rb
+++ /dev/null
@@ -1,21 +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.
-#
-
-def sayHello(s)
- return "Hello " + s + " from " + $greeter
-end \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReference.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReference.composite
deleted file mode 100644
index 175bb79104..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/GroovyReference.composite
+++ /dev/null
@@ -1,38 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="GroovyReference">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="ReferenceComponent"></reference>
- </component>
-
- <component name="ReferenceComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/references/reference.groovy"/>
- <reference name="ref" target="TargetComponent" />
- </component>
-
- <component name="TargetComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.references.HelloWorldTarget"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReference.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReference.composite
deleted file mode 100644
index 7581b633cc..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JRubyReference.composite
+++ /dev/null
@@ -1,38 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JRubyReference">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="ReferenceComponent"></reference>
- </component>
-
- <component name="ReferenceComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/references/reference.rb"/>
- <reference name="ref" target="TargetComponent" />
- </component>
-
- <component name="TargetComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.references.HelloWorldTarget"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReference.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReference.composite
deleted file mode 100644
index 91085b9eb2..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JavaScriptReference.composite
+++ /dev/null
@@ -1,38 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JavaScriptReference">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="ReferenceComponent"></reference>
- </component>
-
- <component name="ReferenceComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/references/reference.js"/>
- <reference name="ref" target="TargetComponent" />
- </component>
-
- <component name="TargetComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.references.HelloWorldTarget"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JythonReference.composite b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JythonReference.composite
deleted file mode 100644
index 535164aae7..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/JythonReference.composite
+++ /dev/null
@@ -1,38 +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"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"
- name="JavaScriptReference">
-
- <component name="ClientComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorldProxy"/>
- <reference name="delegate" target="ReferenceComponent"></reference>
- </component>
-
- <component name="ReferenceComponent">
- <tuscany:implementation.script script="org/apache/tuscany/sca/implementation/script/itests/references/reference.py"/>
- <reference name="ref" target="TargetComponent" />
- </component>
-
- <component name="TargetComponent">
- <implementation.java class="org.apache.tuscany.sca.implementation.script.itests.references.HelloWorldTarget"/>
- </component>
-
-</composite>
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.componentType b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.componentType
deleted file mode 100644
index 3edd075126..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.componentType
+++ /dev/null
@@ -1,31 +0,0 @@
-<?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">
-
- <service name="HelloWorldService">
- <interface.java interface="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorld" />
- </service>
-
- <reference name="ref">
- <interface.java interface="org.apache.tuscany.sca.implementation.script.itests.helloworld.HelloWorld" />
- </reference>
-
-</componentType>
- \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.groovy b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.groovy
deleted file mode 100644
index 5d2216d583..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.groovy
+++ /dev/null
@@ -1,22 +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.
- */
-
-def sayHello(s) {
- return ref.sayHello(s)
-}
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.js b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.js
deleted file mode 100644
index ad0a932d26..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.js
+++ /dev/null
@@ -1,22 +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.
- */
-
-function sayHello(s) {
- return ref.sayHello(s);
-} \ No newline at end of file
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.py b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.py
deleted file mode 100644
index aee8bf991d..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.py
+++ /dev/null
@@ -1,20 +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.
-#
-
-def sayHello(s):
- return ref.sayHello(s)
diff --git a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.rb b/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.rb
deleted file mode 100644
index 87f0f56082..0000000000
--- a/java/sca-contrib/modules/implementation-script-runtime/src/test/resources/org/apache/tuscany/sca/implementation/script/itests/references/reference.rb
+++ /dev/null
@@ -1,21 +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.
-#
-
-def sayHello(s)
- return $ref.sayHello(s)
-end \ No newline at end of file