camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r1155331 - in /camel/branches/camel-2.8.x: ./ components/camel-cxf-transport/src/main/resources/META-INF/services/org/apache/camel/component/ components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/
Date Tue, 09 Aug 2011 12:20:14 GMT
Author: ningjiang
Date: Tue Aug  9 12:20:14 2011
New Revision: 1155331

URL: http://svn.apache.org/viewvc?rev=1155331&view=rev
Log:
Merged revisions 1155231,1155276,1155327 via svnmerge from 
https://svn.apache.org/repos/asf/camel/trunk

........
  r1155231 | ningjiang | 2011-08-09 14:56:01 +0800 (Tue, 09 Aug 2011) | 1 line
  
  CAMEL-4299 Fixed the NPE issue of camel-cxfbean
........
  r1155276 | ningjiang | 2011-08-09 17:20:44 +0800 (Tue, 09 Aug 2011) | 1 line
  
  CAMEL-4299 Fixed the cxfbean component auto load issue
........
  r1155327 | ningjiang | 2011-08-09 20:07:31 +0800 (Tue, 09 Aug 2011) | 1 line
  
  CAMEL-4299 Fixed the CS errors of CxfBeanEndpoint
........

Removed:
    camel/branches/camel-2.8.x/components/camel-cxf-transport/src/main/resources/META-INF/services/org/apache/camel/component/cxfbean
Modified:
    camel/branches/camel-2.8.x/   (props changed)
    camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanComponent.java
    camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanEndpoint.java

Propchange: camel/branches/camel-2.8.x/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Aug  9 12:20:14 2011
@@ -1 +1 @@
-/camel/trunk:1-1148091,1149488,1153146,1153323,1155229
+/camel/trunk:1-1148091,1149488,1153146,1153323,1155229,1155231,1155233-1155276,1155278-1155291,1155293-1155318,1155320-1155327

Modified: camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanComponent.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanComponent.java?rev=1155331&r1=1155330&r2=1155331&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanComponent.java
(original)
+++ camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanComponent.java
Tue Aug  9 12:20:14 2011
@@ -64,23 +64,7 @@ public class CxfBeanComponent extends He
         // we invoke setProperties ourselves so the bus is set for CxfBeanEndpoint.init()
         return false;
     }
-    
-    @Override
-    protected void doStart() throws Exception {
-        super.doStart();
-        for (CxfBeanEndpoint endpoint : endpoints.values()) {
-            endpoint.start();
-        }
-    }
 
-    @Override
-    protected void doStop() throws Exception {
-        for (CxfBeanEndpoint endpoint : endpoints.values()) {
-            endpoint.stop();
-        }
-        super.doStop();
-    }
-    
     public CxfBeanEndpoint getEndpoint(String endpointUri) {
         return endpoints.get(endpointUri);
     }

Modified: camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanEndpoint.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanEndpoint.java?rev=1155331&r1=1155330&r2=1155331&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanEndpoint.java
(original)
+++ camel/branches/camel-2.8.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/cxfbean/CxfBeanEndpoint.java
Tue Aug  9 12:20:14 2011
@@ -37,12 +37,12 @@ import org.apache.cxf.jaxws.JaxWsServerF
 import org.apache.cxf.transport.ConduitInitiatorManager;
 import org.apache.cxf.transport.DestinationFactoryManager;
 
+
 /**
  * CXF Bean Endpoint is a {@link ProcessorEndpoint} which associated with 
  * a {@link CxfBeanDestination}.  It delegates the processing of Camel 
  * Exchanges to the associated CxfBeanDestination.
  *  
- * @version 
  */
 public class CxfBeanEndpoint extends ProcessorEndpoint implements HeaderFilterStrategyAware
{
     private static final String URI_PREFIX = "cxfbean";
@@ -82,7 +82,14 @@ public class CxfBeanEndpoint extends Pro
         }
         
         if (bus == null) {
-            bus = BusFactory.newInstance().createBus();
+            ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
+            try {
+                // Using the class loader of BusFactory to load the Bus
+                Thread.currentThread().setContextClassLoader(BusFactory.class.getClassLoader());
+                bus = BusFactory.newInstance().createBus();
+            } finally {
+                Thread.currentThread().setContextClassLoader(oldCL);
+            }
         }
         
         if (isSetDefaultBus) {



Mime
View raw message