diff options
author | wjaniszewski <wjaniszewski@13f79535-47bb-0310-9956-ffa450edef68> | 2009-04-18 15:48:01 +0000 |
---|---|---|
committer | wjaniszewski <wjaniszewski@13f79535-47bb-0310-9956-ffa450edef68> | 2009-04-18 15:48:01 +0000 |
commit | 8f70a12249558f8b342a57740b6d6423ea23da57 (patch) | |
tree | ccfea4c62bf67c2d5827943e3128b6e415c1a87c /branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java | |
parent | 001f5d05380840d811c85547c361ae0fde5a35a1 (diff) |
General improvements
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@766345 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java')
-rw-r--r-- | branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java | 22 |
1 files changed, 7 insertions, 15 deletions
diff --git a/branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java b/branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java index 26b772f5e3..9e292fe3bb 100644 --- a/branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java +++ b/branches/sca-java-1.x/modules/binding-erlang-runtime/src/main/java/org/apache/tuscany/sca/binding/erlang/impl/ServiceExecutor.java @@ -152,10 +152,8 @@ public class ServiceExecutor implements Runnable { && operation.getOutputType().getPhysical() .isArray()) { // output type is array - Annotation[][] outNotes = new Annotation[][] { jmethod - .getAnnotations() }; - response = TypeHelpersProxy.toErlangAsList(result, - outNotes); + response = TypeHelpersProxy.toErlangAsResultList( + result, jmethod.getAnnotations()); } else if (operation.getOutputType() == null) { // output type is void, create empty reply Object[] arrArg = new Object[] {}; @@ -248,8 +246,7 @@ public class ServiceExecutor implements Runnable { msgNoSender = msg.getMsg(); } } catch (Exception e) { - // TODO: check when this exception can occur - e.printStackTrace(); + logger.log(Level.WARNING, "Unexpected error", e); } if (operations == null) { @@ -294,10 +291,8 @@ public class ServiceExecutor implements Runnable { && matchedOperation.getOutputType().getPhysical() .isArray()) { // result type is array - Annotation[][] outNotes = new Annotation[][] { jmethod - .getAnnotations() }; - response = TypeHelpersProxy.toErlangAsList(result, - outNotes); + response = TypeHelpersProxy.toErlangAsResultList( + result, jmethod.getAnnotations()); } else if (matchedOperation.getOutputType() != null) { // result type is not array and not void response = TypeHelpersProxy.toErlang(result, jmethod @@ -330,13 +325,10 @@ public class ServiceExecutor implements Runnable { e1.printStackTrace(); } } else { - // unknown/unhandled error - // TODO: decide what to do with this exception - e.printStackTrace(); + logger.log(Level.WARNING, "Unexpected error", e); } } catch (Exception e) { - // FIXME: log this problem? use linking feature? send error? - e.printStackTrace(); + logger.log(Level.WARNING, "Unexpected error", e); } } else { // TODO: externalize message? |