servicemix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ff...@apache.org
Subject svn commit: r727906 - in /servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi: container/JBIContainer.java framework/ComponentMBeanImpl.java
Date Fri, 19 Dec 2008 03:13:48 GMT
Author: ffang
Date: Thu Dec 18 19:13:47 2008
New Revision: 727906

URL: http://svn.apache.org/viewvc?rev=727906&view=rev
Log:
[SM-1741]refactor utils to let component get rid of provided dependency of servicemix-core


Modified:
    servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/container/JBIContainer.java
    servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/framework/ComponentMBeanImpl.java

Modified: servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/container/JBIContainer.java
URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/container/JBIContainer.java?rev=727906&r1=727905&r2=727906&view=diff
==============================================================================
--- servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/container/JBIContainer.java
(original)
+++ servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/container/JBIContainer.java
Thu Dec 18 19:13:47 2008
@@ -59,6 +59,7 @@
 import org.apache.servicemix.executors.ExecutorFactory;
 import org.apache.servicemix.executors.impl.ExecutorFactoryImpl;
 import org.apache.servicemix.id.IdGenerator;
+import org.apache.servicemix.jbi.api.ComponentUtil;
 import org.apache.servicemix.jbi.api.Container;
 import org.apache.servicemix.jbi.event.ComponentListener;
 import org.apache.servicemix.jbi.event.ContainerAware;
@@ -1029,6 +1030,16 @@
     }
 
     /**
+     * Get the component associated with the given component ID
+     *
+     * @param componentName
+     * @return the component
+     */
+    public ComponentUtil getComponentByName(String componentName) {
+        return registry.getComponent(componentName);
+    }
+
+    /**
      * @return all local ComponentConnectors
      */
     public Collection getLocalComponentConnectors() {

Modified: servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/framework/ComponentMBeanImpl.java
URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/framework/ComponentMBeanImpl.java?rev=727906&r1=727905&r2=727906&view=diff
==============================================================================
--- servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/framework/ComponentMBeanImpl.java
(original)
+++ servicemix/smx3/trunk/core/servicemix-core/src/main/java/org/apache/servicemix/jbi/framework/ComponentMBeanImpl.java
Thu Dec 18 19:13:47 2008
@@ -33,6 +33,7 @@
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.servicemix.jbi.api.ComponentUtil;
 import org.apache.servicemix.jbi.container.ActivationSpec;
 import org.apache.servicemix.jbi.container.JBIContainer;
 import org.apache.servicemix.jbi.event.ComponentEvent;
@@ -48,7 +49,7 @@
 /**
  * Defines basic statistics on the Component
  */
-public class ComponentMBeanImpl extends BaseLifeCycle implements ComponentMBean {
+public class ComponentMBeanImpl extends BaseLifeCycle implements ComponentMBean, ComponentUtil
{
     
     private static final Log LOG = LogFactory.getLog(ComponentMBeanImpl.class);
     



Mime
View raw message