camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r905256 - in /camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf: CxfEndpoint.java spring/CxfEndpointBeanDefinitionParser.java
Date Mon, 01 Feb 2010 11:29:46 GMT
Author: ningjiang
Date: Mon Feb  1 11:29:45 2010
New Revision: 905256

URL: http://svn.apache.org/viewvc?rev=905256&view=rev
Log:
CAMEL-2433 Camel CxfEndpoint should support the set the bus from URI

Modified:
    camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/CxfEndpoint.java
    camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/spring/CxfEndpointBeanDefinitionParser.java

Modified: camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/CxfEndpoint.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/CxfEndpoint.java?rev=905256&r1=905255&r2=905256&view=diff
==============================================================================
--- camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/CxfEndpoint.java
(original)
+++ camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/CxfEndpoint.java
Mon Feb  1 11:29:45 2010
@@ -117,6 +117,10 @@
         return new CxfExchange(getCamelContext(), getExchangePattern(), inMessage);
     }
     
+    public void setBus(Bus bus) {
+        this.bus = bus;
+    }
+    
     public Bus getBus() {
         if (bus == null) {
             bus = doGetBus();

Modified: camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/spring/CxfEndpointBeanDefinitionParser.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/spring/CxfEndpointBeanDefinitionParser.java?rev=905256&r1=905255&r2=905256&view=diff
==============================================================================
--- camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/spring/CxfEndpointBeanDefinitionParser.java
(original)
+++ camel/branches/camel-1.x/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/spring/CxfEndpointBeanDefinitionParser.java
Mon Feb  1 11:29:45 2010
@@ -23,6 +23,7 @@
 import org.apache.cxf.Bus;
 import org.apache.cxf.BusFactory;
 import org.apache.cxf.bus.spring.BusWiringBeanFactoryPostProcessor;
+import org.apache.cxf.bus.spring.SpringBusFactory;
 import org.apache.cxf.common.util.StringUtils;
 import org.apache.cxf.configuration.spring.AbstractBeanDefinitionParser;
 import org.apache.cxf.service.factory.ReflectionServiceFactoryBean;
@@ -110,7 +111,8 @@
         
         public void setApplicationContext(ApplicationContext ctx) throws BeansException {
             if (getBus() == null) {
-                Bus bus = BusFactory.getDefaultBus();                
+                SpringBusFactory busFactory = new SpringBusFactory(ctx);
+                Bus bus = busFactory.createBus();
                 setBus(bus);
             }
             BusWiringBeanFactoryPostProcessor.updateBusReferencesInContext(getBus(), ctx);
         



Mime
View raw message