camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1050438 - /camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
Date Fri, 17 Dec 2010 16:11:57 GMT
Author: davsclaus
Date: Fri Dec 17 16:11:56 2010
New Revision: 1050438

URL: http://svn.apache.org/viewvc?rev=1050438&view=rev
Log:
XML should auto lookup custom ManagementNamingStrategy

Modified:
    camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java

Modified: camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java?rev=1050438&r1=1050437&r2=1050438&view=diff
==============================================================================
--- camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
(original)
+++ camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
Fri Dec 17 16:11:56 2010
@@ -72,6 +72,7 @@ import org.apache.camel.spi.FactoryFinde
 import org.apache.camel.spi.InflightRepository;
 import org.apache.camel.spi.InterceptStrategy;
 import org.apache.camel.spi.LifecycleStrategy;
+import org.apache.camel.spi.ManagementNamingStrategy;
 import org.apache.camel.spi.ManagementStrategy;
 import org.apache.camel.spi.PackageScanClassResolver;
 import org.apache.camel.spi.PackageScanFilter;
@@ -211,6 +212,11 @@ public abstract class AbstractCamelConte
             LOG.info("Using custom ManagementStrategy: " + managementStrategy);
             getContext().setManagementStrategy(managementStrategy);
         }
+        ManagementNamingStrategy managementNamingStrategy = getBeanForType(ManagementNamingStrategy.class);
+        if (managementNamingStrategy != null) {
+            LOG.info("Using custom ManagementNamingStrategy: " + managementNamingStrategy);
+            getContext().getManagementStrategy().setManagementNamingStrategy(managementNamingStrategy);
+        }
         EventFactory eventFactory = getBeanForType(EventFactory.class);
         if (eventFactory != null) {
             LOG.info("Using custom EventFactory: " + eventFactory);



Mime
View raw message