cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r443490 - in /incubator/cxf/trunk: api/src/main/java/org/apache/cxf/workqueue/ rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/ rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/ rt/core/src/main/java/org/apach...
Date Thu, 14 Sep 2006 21:46:35 GMT
Author: dkulp
Date: Thu Sep 14 14:46:33 2006
New Revision: 443490

URL: http://svn.apache.org/viewvc?view=rev&rev=443490
Log:
BUNCH more svn property updates


Modified:
    incubator/cxf/trunk/api/src/main/java/org/apache/cxf/workqueue/AutomaticWorkQueue.java
  (props changed)
    incubator/cxf/trunk/api/src/main/java/org/apache/cxf/workqueue/WorkQueue.java   (props
changed)
    incubator/cxf/trunk/api/src/main/java/org/apache/cxf/workqueue/WorkQueueManager.java 
 (props changed)
    incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/RPCInInterceptor.java
  (props changed)
    incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/RPCOutInterceptor.java
  (props changed)
    incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/Soap11FaultInInterceptor.java
  (props changed)
    incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/Soap11FaultOutInterceptor.java
  (props changed)
    incubator/cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/XMLConstants.java
  (props changed)
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ServerRegistryImpl.java
  (props changed)
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/AutomaticWorkQueueImpl.java
  (props changed)
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/Messages.properties
  (props changed)
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/WorkQueueInstrumentation.java
  (props changed)
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/WorkQueueManagerImpl.java
  (props changed)
    incubator/cxf/trunk/rt/core/src/test/java/org/apache/cxf/endpoint/ServerRegistryImpTest.java
  (props changed)
    incubator/cxf/trunk/rt/core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java
  (props changed)
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/DispatchImpl.java
  (contents, props changed)
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsUtils.java
  (props changed)
    incubator/cxf/trunk/rt/management/src/test/java/org/apache/cxf/management/InstrumentationManagerTest.java
  (props changed)
    incubator/cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportBase.java
  (props changed)
    incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/AbstractJMSTester.java
  (props changed)
    incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSBrokerSetup.java
  (props changed)
    incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConduitTest.java
  (props changed)
    incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigurationTest.java
  (props changed)
    incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSDestinationTest.java
  (props changed)
    incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java
  (props changed)
    incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/AddressingBuilderImplTest.java
  (props changed)
    incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/AddressingBuilderTest.java
  (props changed)
    incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/AddressingConstantsImplTest.java
  (props changed)
    incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/jaxws/ClientServerRPCLitTest.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/jaxws/ClientServerXMLBareTest.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/jaxws/ClientServerXMLWrapTest.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/EmbeddedJMSBrokerLauncher.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplDoc.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplQueueOneWay.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplTopicOneWay.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplTwoWayJMS.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/JMSClientServerTest.java
  (props changed)
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/Server.java   (props
changed)
    incubator/cxf/trunk/testutils/src/main/java/org/apache/hello_world_soap_http/RPCLitGreeterImpl.java
  (props changed)
    incubator/cxf/trunk/testutils/src/main/java/org/apache/hello_world_xml_http/bare/GreeterImpl.java
  (props changed)

Propchange: incubator/cxf/trunk/api/src/main/java/org/apache/cxf/workqueue/AutomaticWorkQueue.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/api/src/main/java/org/apache/cxf/workqueue/WorkQueue.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/api/src/main/java/org/apache/cxf/workqueue/WorkQueueManager.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/RPCInInterceptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/RPCOutInterceptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/Soap11FaultInInterceptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/Soap11FaultOutInterceptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/XMLConstants.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ServerRegistryImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ServerRegistryImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/AutomaticWorkQueueImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/Messages.properties
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/WorkQueueInstrumentation.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/workqueue/WorkQueueManagerImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/test/java/org/apache/cxf/endpoint/ServerRegistryImpTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/core/src/test/java/org/apache/cxf/endpoint/ServerRegistryImpTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/DispatchImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/DispatchImpl.java?view=diff&rev=443490&r1=443489&r2=443490
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/DispatchImpl.java
(original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/DispatchImpl.java
Thu Sep 14 14:46:33 2006
@@ -1,275 +1,275 @@
-/**
- * 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.cxf.jaxws;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.concurrent.Executor;
-import java.util.concurrent.Executors;
-import java.util.concurrent.Future;
-import java.util.concurrent.FutureTask;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-import javax.xml.bind.JAXBContext;
-import javax.xml.ws.AsyncHandler;
-import javax.xml.ws.Dispatch;
-import javax.xml.ws.Response;
-import javax.xml.ws.Service;
-
-import org.apache.cxf.Bus;
-import org.apache.cxf.BusException;
-import org.apache.cxf.common.logging.LogUtils;
-import org.apache.cxf.endpoint.Endpoint;
-import org.apache.cxf.interceptor.Interceptor;
-import org.apache.cxf.interceptor.MessageSenderInterceptor;
-import org.apache.cxf.jaxws.interceptors.DispatchInInterceptor;
-import org.apache.cxf.jaxws.interceptors.DispatchOutInterceptor;
-import org.apache.cxf.message.Exchange;
-import org.apache.cxf.message.ExchangeImpl;
-import org.apache.cxf.message.Message;
-import org.apache.cxf.phase.PhaseInterceptorChain;
-import org.apache.cxf.phase.PhaseManager;
-import org.apache.cxf.service.model.EndpointInfo;
-import org.apache.cxf.transport.Conduit;
-import org.apache.cxf.transport.ConduitInitiator;
-import org.apache.cxf.transport.ConduitInitiatorManager;
-import org.apache.cxf.transport.MessageObserver;
-
-public class DispatchImpl<T> extends BindingProviderImpl implements Dispatch<T>,
MessageObserver {
-    private static final Logger LOG = LogUtils.getL7dLogger(DispatchImpl.class);
-
-    private Bus bus;
-
-    private Class<T> cl;
-    private Executor executor;
-    private JAXBContext context;
-    private Service.Mode mode;
-
-    private Endpoint endpoint;
-
-    DispatchImpl(Bus b, Service.Mode m, Class<T> clazz, Executor e, Endpoint ep) {
-        bus = b;
-        cl = clazz;
-        executor = e;
-        mode = m;
-
-        endpoint = ep;
-    }
-
-    DispatchImpl(Bus b, Service.Mode m, JAXBContext ctx, Class<T> clazz, Executor e,
Endpoint ep) {
-        bus = b;
-        executor = e;
-        context = ctx;
-        cl = clazz;
-        mode = m;
-
-        endpoint = ep;
-    }
-
-    public T invoke(T obj) {
-        return invoke(obj, false);
-    }
-
-    public T invoke(T obj, boolean isOneWay) {
-        if (LOG.isLoggable(Level.INFO)) {
-            LOG.info("Dispatch: invoke called");
-        }
-
-        System.err.println("INVOKING...");
-
-        Message message = endpoint.getBinding().createMessage();
-
-        if (context != null) {
-            message.setContent(JAXBContext.class, context);
-        }
-
-        Exchange exchange = new ExchangeImpl();
-        exchange.put(Service.Mode.class, mode);
-        exchange.put(Class.class, cl);
-        exchange.put(org.apache.cxf.service.Service.class, endpoint.getService());
-
-        exchange.setOutMessage(message);
-        message.setExchange(exchange);
-
-        message.setContent(Object.class, obj);
-
-        PhaseInterceptorChain chain = getDispatchOutChain();
-        message.setInterceptorChain(chain);
-
-        // setup conduit
-        Conduit conduit = getConduit();
-        exchange.setConduit(conduit);
-        conduit.setMessageObserver(this);
-
-        // execute chain
-        chain.doIntercept(message);
-
-        if (message.getContent(Exception.class) != null) {
-            throw new RuntimeException(message.get(Exception.class));
-        }
-
-        // correlate response        
-        if (conduit.getBackChannel() != null) {
-            // process partial response and wait for decoupled response
-        } else {
-            // process response: send was synchronous so when we get here we can assume that
the 
-            // Exchange's inbound message is set and had been passed through the inbound
interceptor chain.
-        }
-
-        if (!isOneWay) {
-            synchronized (exchange) {
-                Message inMsg = waitResponse(exchange);
-                return cl.cast(inMsg.getContent(Object.class));
-            }
-        }
-        return null;
-        //         populateResponseContext(objMsgContext);
-        //         return cl.cast(objMsgContext.getReturn());
-    }
-
-    private Message waitResponse(Exchange exchange) {
-        Message inMsg = exchange.getInMessage();
-        if (inMsg == null) {
-            try {
-                exchange.wait();
-            } catch (InterruptedException e) {
-                //TODO - timeout
-            }
-            inMsg = exchange.getInMessage();
-        }
-        if (inMsg.getContent(Exception.class) != null) {
-            //TODO - exceptions 
-            throw new RuntimeException(inMsg.getContent(Exception.class));
-        }
-        return inMsg;
-    }
-
-    private PhaseInterceptorChain getDispatchOutChain() {
-        PhaseManager pm = bus.getExtension(PhaseManager.class);
-        PhaseInterceptorChain chain = new PhaseInterceptorChain(pm.getOutPhases());
-
-        List<Interceptor> il = bus.getOutInterceptors();
-        if (LOG.isLoggable(Level.FINE)) {
-            LOG.fine("Interceptors contributed by bus: " + il);
-        }
-        chain.add(il);
-        il = endpoint.getOutInterceptors();
-        if (LOG.isLoggable(Level.FINE)) {
-            LOG.fine("Interceptors contributed by endpoint: " + il);
-        }
-        chain.add(il);
-
-        List<Interceptor> outInterceptors = new ArrayList<Interceptor>();
-        outInterceptors.add(new MessageSenderInterceptor());
-        outInterceptors.add(new DispatchOutInterceptor());
-
-        chain.add(outInterceptors);
-
-        return chain;
-    }
-
-    public void onMessage(Message message) {
-        message = endpoint.getBinding().createMessage(message);
-
-        message.put(Message.REQUESTOR_ROLE, Boolean.TRUE);
-
-        PhaseManager pm = bus.getExtension(PhaseManager.class);
-        PhaseInterceptorChain chain = new PhaseInterceptorChain(pm.getInPhases());
-        message.setInterceptorChain(chain);
-
-        List<Interceptor> il = bus.getInInterceptors();
-        if (LOG.isLoggable(Level.FINE)) {
-            LOG.fine("Interceptors contributed by bus: " + il);
-        }
-        chain.add(il);
-        il = endpoint.getInInterceptors();
-        if (LOG.isLoggable(Level.FINE)) {
-            LOG.fine("Interceptors contributed by endpoint: " + il);
-        }
-        chain.add(il);
-
-        List<Interceptor> inInterceptors = new ArrayList<Interceptor>();
-        inInterceptors.add(new DispatchInInterceptor());
-        chain.add(inInterceptors);
-
-        // execute chain
-        try {
-            chain.doIntercept(message);
-        } finally {
-            synchronized (message.getExchange()) {
-                message.getExchange().setInMessage(message);
-                message.getExchange().notifyAll();
-            }
-        }
-    }
-
-    private Conduit getConduit() {
-        EndpointInfo ei = endpoint.getEndpointInfo();
-        String transportID = ei.getTransportId();
-        try {
-            ConduitInitiator ci = bus.getExtension(ConduitInitiatorManager.class)
-                .getConduitInitiator(transportID);
-            return ci.getConduit(ei);
-        } catch (BusException ex) {
-            // TODO: wrap in runtime exception
-            ex.printStackTrace();
-        } catch (IOException ex) {
-            // TODO: wrap in runtime exception
-            ex.printStackTrace();
-        }
-
-        return null;
-    }
-
-    private Executor getExecutor() {
-        if (executor == null) {
-            executor = endpoint.getService().getExecutor();
-        }
-        if (executor == null) {
-            executor = Executors.newFixedThreadPool(5);
-        }
-        if (executor == null) {
-            System.err.println("Can't not get executor");
-        }
-        return executor;
-    }
-
-    public Future<?> invokeAsync(T obj, AsyncHandler<T> asyncHandler) {
-        Response<?> r = invokeAsync(obj);
-        AsyncCallbackFuture callback = new AsyncCallbackFuture(r, asyncHandler);
-
-        getExecutor().execute(callback);
-        return callback;
-    }
-
-    @SuppressWarnings("unchecked")
-    public Response<T> invokeAsync(T obj) {
-        FutureTask<T> f = new FutureTask<T>(new DispatchAsyncCallable<T>(this,
obj));
-
-        getExecutor().execute(f);
-        return new AsyncResponse<T>(f, cl);
-    }
-
-    public void invokeOneWay(T obj) {
-        invoke(obj, true);
-    }
-}
+/**
+ * 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.cxf.jaxws;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.concurrent.Executor;
+import java.util.concurrent.Executors;
+import java.util.concurrent.Future;
+import java.util.concurrent.FutureTask;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+import javax.xml.bind.JAXBContext;
+import javax.xml.ws.AsyncHandler;
+import javax.xml.ws.Dispatch;
+import javax.xml.ws.Response;
+import javax.xml.ws.Service;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusException;
+import org.apache.cxf.common.logging.LogUtils;
+import org.apache.cxf.endpoint.Endpoint;
+import org.apache.cxf.interceptor.Interceptor;
+import org.apache.cxf.interceptor.MessageSenderInterceptor;
+import org.apache.cxf.jaxws.interceptors.DispatchInInterceptor;
+import org.apache.cxf.jaxws.interceptors.DispatchOutInterceptor;
+import org.apache.cxf.message.Exchange;
+import org.apache.cxf.message.ExchangeImpl;
+import org.apache.cxf.message.Message;
+import org.apache.cxf.phase.PhaseInterceptorChain;
+import org.apache.cxf.phase.PhaseManager;
+import org.apache.cxf.service.model.EndpointInfo;
+import org.apache.cxf.transport.Conduit;
+import org.apache.cxf.transport.ConduitInitiator;
+import org.apache.cxf.transport.ConduitInitiatorManager;
+import org.apache.cxf.transport.MessageObserver;
+
+public class DispatchImpl<T> extends BindingProviderImpl implements Dispatch<T>,
MessageObserver {
+    private static final Logger LOG = LogUtils.getL7dLogger(DispatchImpl.class);
+
+    private Bus bus;
+
+    private Class<T> cl;
+    private Executor executor;
+    private JAXBContext context;
+    private Service.Mode mode;
+
+    private Endpoint endpoint;
+
+    DispatchImpl(Bus b, Service.Mode m, Class<T> clazz, Executor e, Endpoint ep) {
+        bus = b;
+        cl = clazz;
+        executor = e;
+        mode = m;
+
+        endpoint = ep;
+    }
+
+    DispatchImpl(Bus b, Service.Mode m, JAXBContext ctx, Class<T> clazz, Executor e,
Endpoint ep) {
+        bus = b;
+        executor = e;
+        context = ctx;
+        cl = clazz;
+        mode = m;
+
+        endpoint = ep;
+    }
+
+    public T invoke(T obj) {
+        return invoke(obj, false);
+    }
+
+    public T invoke(T obj, boolean isOneWay) {
+        if (LOG.isLoggable(Level.INFO)) {
+            LOG.info("Dispatch: invoke called");
+        }
+
+        System.err.println("INVOKING...");
+
+        Message message = endpoint.getBinding().createMessage();
+
+        if (context != null) {
+            message.setContent(JAXBContext.class, context);
+        }
+
+        Exchange exchange = new ExchangeImpl();
+        exchange.put(Service.Mode.class, mode);
+        exchange.put(Class.class, cl);
+        exchange.put(org.apache.cxf.service.Service.class, endpoint.getService());
+
+        exchange.setOutMessage(message);
+        message.setExchange(exchange);
+
+        message.setContent(Object.class, obj);
+
+        PhaseInterceptorChain chain = getDispatchOutChain();
+        message.setInterceptorChain(chain);
+
+        // setup conduit
+        Conduit conduit = getConduit();
+        exchange.setConduit(conduit);
+        conduit.setMessageObserver(this);
+
+        // execute chain
+        chain.doIntercept(message);
+
+        if (message.getContent(Exception.class) != null) {
+            throw new RuntimeException(message.get(Exception.class));
+        }
+
+        // correlate response        
+        if (conduit.getBackChannel() != null) {
+            // process partial response and wait for decoupled response
+        } else {
+            // process response: send was synchronous so when we get here we can assume that
the 
+            // Exchange's inbound message is set and had been passed through the inbound
interceptor chain.
+        }
+
+        if (!isOneWay) {
+            synchronized (exchange) {
+                Message inMsg = waitResponse(exchange);
+                return cl.cast(inMsg.getContent(Object.class));
+            }
+        }
+        return null;
+        //         populateResponseContext(objMsgContext);
+        //         return cl.cast(objMsgContext.getReturn());
+    }
+
+    private Message waitResponse(Exchange exchange) {
+        Message inMsg = exchange.getInMessage();
+        if (inMsg == null) {
+            try {
+                exchange.wait();
+            } catch (InterruptedException e) {
+                //TODO - timeout
+            }
+            inMsg = exchange.getInMessage();
+        }
+        if (inMsg.getContent(Exception.class) != null) {
+            //TODO - exceptions 
+            throw new RuntimeException(inMsg.getContent(Exception.class));
+        }
+        return inMsg;
+    }
+
+    private PhaseInterceptorChain getDispatchOutChain() {
+        PhaseManager pm = bus.getExtension(PhaseManager.class);
+        PhaseInterceptorChain chain = new PhaseInterceptorChain(pm.getOutPhases());
+
+        List<Interceptor> il = bus.getOutInterceptors();
+        if (LOG.isLoggable(Level.FINE)) {
+            LOG.fine("Interceptors contributed by bus: " + il);
+        }
+        chain.add(il);
+        il = endpoint.getOutInterceptors();
+        if (LOG.isLoggable(Level.FINE)) {
+            LOG.fine("Interceptors contributed by endpoint: " + il);
+        }
+        chain.add(il);
+
+        List<Interceptor> outInterceptors = new ArrayList<Interceptor>();
+        outInterceptors.add(new MessageSenderInterceptor());
+        outInterceptors.add(new DispatchOutInterceptor());
+
+        chain.add(outInterceptors);
+
+        return chain;
+    }
+
+    public void onMessage(Message message) {
+        message = endpoint.getBinding().createMessage(message);
+
+        message.put(Message.REQUESTOR_ROLE, Boolean.TRUE);
+
+        PhaseManager pm = bus.getExtension(PhaseManager.class);
+        PhaseInterceptorChain chain = new PhaseInterceptorChain(pm.getInPhases());
+        message.setInterceptorChain(chain);
+
+        List<Interceptor> il = bus.getInInterceptors();
+        if (LOG.isLoggable(Level.FINE)) {
+            LOG.fine("Interceptors contributed by bus: " + il);
+        }
+        chain.add(il);
+        il = endpoint.getInInterceptors();
+        if (LOG.isLoggable(Level.FINE)) {
+            LOG.fine("Interceptors contributed by endpoint: " + il);
+        }
+        chain.add(il);
+
+        List<Interceptor> inInterceptors = new ArrayList<Interceptor>();
+        inInterceptors.add(new DispatchInInterceptor());
+        chain.add(inInterceptors);
+
+        // execute chain
+        try {
+            chain.doIntercept(message);
+        } finally {
+            synchronized (message.getExchange()) {
+                message.getExchange().setInMessage(message);
+                message.getExchange().notifyAll();
+            }
+        }
+    }
+
+    private Conduit getConduit() {
+        EndpointInfo ei = endpoint.getEndpointInfo();
+        String transportID = ei.getTransportId();
+        try {
+            ConduitInitiator ci = bus.getExtension(ConduitInitiatorManager.class)
+                .getConduitInitiator(transportID);
+            return ci.getConduit(ei);
+        } catch (BusException ex) {
+            // TODO: wrap in runtime exception
+            ex.printStackTrace();
+        } catch (IOException ex) {
+            // TODO: wrap in runtime exception
+            ex.printStackTrace();
+        }
+
+        return null;
+    }
+
+    private Executor getExecutor() {
+        if (executor == null) {
+            executor = endpoint.getService().getExecutor();
+        }
+        if (executor == null) {
+            executor = Executors.newFixedThreadPool(5);
+        }
+        if (executor == null) {
+            System.err.println("Can't not get executor");
+        }
+        return executor;
+    }
+
+    public Future<?> invokeAsync(T obj, AsyncHandler<T> asyncHandler) {
+        Response<?> r = invokeAsync(obj);
+        AsyncCallbackFuture callback = new AsyncCallbackFuture(r, asyncHandler);
+
+        getExecutor().execute(callback);
+        return callback;
+    }
+
+    @SuppressWarnings("unchecked")
+    public Response<T> invokeAsync(T obj) {
+        FutureTask<T> f = new FutureTask<T>(new DispatchAsyncCallable<T>(this,
obj));
+
+        getExecutor().execute(f);
+        return new AsyncResponse<T>(f, cl);
+    }
+
+    public void invokeOneWay(T obj) {
+        invoke(obj, true);
+    }
+}

Propchange: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/DispatchImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsUtils.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/management/src/test/java/org/apache/cxf/management/InstrumentationManagerTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportBase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/AbstractJMSTester.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSBrokerSetup.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConduitTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigurationTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSDestinationTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/AddressingBuilderImplTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/AddressingBuilderTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/AddressingConstantsImplTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/jaxws/ClientServerRPCLitTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/jaxws/ClientServerXMLBareTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/jaxws/ClientServerXMLWrapTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/EmbeddedJMSBrokerLauncher.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplDoc.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplQueueOneWay.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplTopicOneWay.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/GreeterImplTwoWayJMS.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/JMSClientServerTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jms/Server.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/testutils/src/main/java/org/apache/hello_world_soap_http/RPCLitGreeterImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/testutils/src/main/java/org/apache/hello_world_xml_http/bare/GreeterImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date



Mime
View raw message