You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by bd...@apache.org on 2009/06/26 22:42:30 UTC
svn commit: r788863 -
/tuscany/branches/sca-java-1.x/modules/binding-http-runtime/src/main/java/org/apache/tuscany/sca/binding/http/provider/HTTPServiceBindingProvider.java
Author: bdaniel
Date: Fri Jun 26 20:42:30 2009
New Revision: 788863
URL: http://svn.apache.org/viewvc?rev=788863&view=rev
Log:
TUSCANY-3124 Check for wireFormat/operationSelector before other operations
Modified:
tuscany/branches/sca-java-1.x/modules/binding-http-runtime/src/main/java/org/apache/tuscany/sca/binding/http/provider/HTTPServiceBindingProvider.java
Modified: tuscany/branches/sca-java-1.x/modules/binding-http-runtime/src/main/java/org/apache/tuscany/sca/binding/http/provider/HTTPServiceBindingProvider.java
URL: http://svn.apache.org/viewvc/tuscany/branches/sca-java-1.x/modules/binding-http-runtime/src/main/java/org/apache/tuscany/sca/binding/http/provider/HTTPServiceBindingProvider.java?rev=788863&r1=788862&r2=788863&view=diff
==============================================================================
--- tuscany/branches/sca-java-1.x/modules/binding-http-runtime/src/main/java/org/apache/tuscany/sca/binding/http/provider/HTTPServiceBindingProvider.java (original)
+++ tuscany/branches/sca-java-1.x/modules/binding-http-runtime/src/main/java/org/apache/tuscany/sca/binding/http/provider/HTTPServiceBindingProvider.java Fri Jun 26 20:42:30 2009
@@ -133,7 +133,11 @@
for (InvocationChain invocationChain : wire.getInvocationChains()) {
Operation operation = invocationChain.getTargetOperation();
String operationName = operation.getName();
- if (operationName.equals("get")) {
+ if (binding.getOperationSelector() != null || binding.getRequestWireFormat() != null) {
+ Invoker bindingInvoker = wire.getBindingInvocationChain().getHeadInvoker();
+ servlet = new HTTPRRBListenerServlet(binding, bindingInvoker, messageFactory);
+ break;
+ } else if (operationName.equals("get")) {
Invoker getInvoker = invocationChain.getHeadInvoker();
bindingListenerServlet.setGetInvoker(getInvoker);
servlet = bindingListenerServlet;
@@ -169,11 +173,7 @@
Invoker serviceInvoker = invocationChain.getHeadInvoker();
servlet = new HTTPServiceListenerServlet(binding, serviceInvoker, messageFactory);
break;
- } else if (binding.getOperationSelector() != null || binding.getRequestWireFormat() != null) {
- Invoker bindingInvoker = wire.getBindingInvocationChain().getHeadInvoker();
- servlet = new HTTPRRBListenerServlet(binding, bindingInvoker, messageFactory);
- break;
- }
+ }
}
if (servlet == null) {
throw new IllegalStateException("No get or service method found on the service");