You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2011/12/21 23:26:03 UTC

svn commit: r1221914 - in /cxf/branches/2.4.x-fixes: ./ rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java

Author: dkulp
Date: Wed Dec 21 22:26:02 2011
New Revision: 1221914

URL: http://svn.apache.org/viewvc?rev=1221914&view=rev
Log:
Merged revisions 1221874 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1221874 | dkulp | 2011-12-21 15:53:07 -0500 (Wed, 21 Dec 2011) | 2 lines
  
  [CXF-3991] Better error message when conduit cannot be found.
  Patch from Andrei Shakirin applied.
........

Modified:
    cxf/branches/2.4.x-fixes/   (props changed)
    cxf/branches/2.4.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java

Propchange: cxf/branches/2.4.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.4.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java?rev=1221914&r1=1221913&r2=1221914&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java (original)
+++ cxf/branches/2.4.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java Wed Dec 21 22:26:02 2011
@@ -62,6 +62,8 @@ import org.apache.cxf.wsdl11.WSDLEndpoin
 public class SoapTransportFactory extends AbstractTransportFactory implements DestinationFactory,
     WSDLEndpointFactory, ConduitInitiator {
     
+    public static final String CANNOT_GET_CONDUIT_ERROR 
+        = "Could not find conduit initiator for address: %s and transport: %s";
     public static final String SOAP_11_HTTP_BINDING = "http://schemas.xmlsoap.org/soap/http";
     public static final String SOAP_12_HTTP_BINDING = "http://www.w3.org/2003/05/soap/bindings/HTTP/";
     
@@ -222,13 +224,11 @@ public class SoapTransportFactory extend
                 conduitInit = mgr.getConduitInitiatorForUri(address);
             }
             if (conduitInit == null) {
-                throw new RuntimeException("Could not find conduit initiator for transport "
-                        + transId);
+                throw new RuntimeException(String.format(CANNOT_GET_CONDUIT_ERROR, address, transId));
             }
             return conduitInit.getConduit(ei, target);
         } catch (BusException e) {
-            throw new RuntimeException("Could not find conduit initiator for transport "
-                                       + transId);
+            throw new RuntimeException(String.format(CANNOT_GET_CONDUIT_ERROR, address, transId));
         }
     }