karaf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbono...@apache.org
Subject git commit: [KARAF-3081] Refactore Cave management to use Aries JMX services
Date Fri, 27 Jun 2014 15:20:27 GMT
Repository: karaf-cave
Updated Branches:
  refs/heads/master e4d040b36 -> 4c03de31a


[KARAF-3081] Refactore Cave management to use Aries JMX services


Project: http://git-wip-us.apache.org/repos/asf/karaf-cave/repo
Commit: http://git-wip-us.apache.org/repos/asf/karaf-cave/commit/4c03de31
Tree: http://git-wip-us.apache.org/repos/asf/karaf-cave/tree/4c03de31
Diff: http://git-wip-us.apache.org/repos/asf/karaf-cave/diff/4c03de31

Branch: refs/heads/master
Commit: 4c03de31a24cfed72b67111b669cf9797aa53edb
Parents: e4d040b
Author: Jean-Baptiste Onofré <jbonofre@apache.org>
Authored: Fri Jun 27 17:19:57 2014 +0200
Committer: Jean-Baptiste Onofré <jbonofre@apache.org>
Committed: Fri Jun 27 17:19:57 2014 +0200

----------------------------------------------------------------------
 assembly/src/main/resources/features.xml        |  2 +-
 server/management/pom.xml                       |  8 +++----
 .../OSGI-INF/blueprint/cave-management.xml      | 25 +++++++++-----------
 3 files changed, 16 insertions(+), 19 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/karaf-cave/blob/4c03de31/assembly/src/main/resources/features.xml
----------------------------------------------------------------------
diff --git a/assembly/src/main/resources/features.xml b/assembly/src/main/resources/features.xml
index 27dc0f1..13ed40f 100644
--- a/assembly/src/main/resources/features.xml
+++ b/assembly/src/main/resources/features.xml
@@ -31,7 +31,7 @@
             mvn:org.apache.karaf.cave/apache-karaf-cave/${project.version}/cfg/filesystem
         </configfile>
         <bundle>mvn:commons-io/commons-io/${commons-io.version}</bundle>
-        <bundle>mvn:org.apache.httpcomponents/httpcore-osgi/${httpclient.version}</bundle>
+        <bundle>mvn:org.apache.httpcomponents/httpcore-osgi/4.3.2</bundle>
         <bundle>mvn:org.apache.httpcomponents/httpclient-osgi/${httpclient.version}</bundle>
         <bundle>mvn:org.jsoup/jsoup/${jsoup.version}</bundle>
         <bundle>mvn:org.apache.karaf.cave.server/org.apache.karaf.cave.server.api/${project.version}</bundle>

http://git-wip-us.apache.org/repos/asf/karaf-cave/blob/4c03de31/server/management/pom.xml
----------------------------------------------------------------------
diff --git a/server/management/pom.xml b/server/management/pom.xml
index b8f7e7a..afac965 100644
--- a/server/management/pom.xml
+++ b/server/management/pom.xml
@@ -53,14 +53,14 @@
                             org.apache.karaf.cave.server.management*;version=${project.version}
                         </Export-Package>
                         <Import-Package>
-                            !org.apache.karaf.cave.server.management*,
                             javax.management,
                             javax.management.loading,
                             javax.management.openmbean,
-                            org.apache.karaf.management*;version="[2,4)",
-                            org.apache.karaf.cave.server.api;version=${project.version},
-                            *
+                            org.apache.karaf.cave.server.api;version=${project.version}
                         </Import-Package>
+                        <Private-Package>
+                            org.apache.karaf.cave.server.management.internal
+                        </Private-Package>
                     </instructions>
                 </configuration>
             </plugin>

http://git-wip-us.apache.org/repos/asf/karaf-cave/blob/4c03de31/server/management/src/main/resources/OSGI-INF/blueprint/cave-management.xml
----------------------------------------------------------------------
diff --git a/server/management/src/main/resources/OSGI-INF/blueprint/cave-management.xml b/server/management/src/main/resources/OSGI-INF/blueprint/cave-management.xml
index 9a629ee..a4b9b3d 100644
--- a/server/management/src/main/resources/OSGI-INF/blueprint/cave-management.xml
+++ b/server/management/src/main/resources/OSGI-INF/blueprint/cave-management.xml
@@ -1,24 +1,21 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0">
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+           xmlns:ext="http://aries.apache.org/blueprint/xmlns/blueprint-ext/v1.0.0">
+
+    <!-- system properties -->
+    <ext:property-placeholder placeholder-prefix="$[" placeholder-suffix="]"/>
 
     <!-- reference to the Cave repository service -->
     <reference id="caveRepositoryService" interface="org.apache.karaf.cave.server.api.CaveRepositoryService"/>
 
-    <!-- reference to the Karaf MBean server -->
-    <reference id="mbeanServer" interface="javax.management.MBeanServer">
-        <reference-listener ref="mbeanRegistrer" bind-method="registerMBeanServer" unbind-method="unregisterMBeanServer"/>
-    </reference>
-
+    <!-- Cave repostiroy MBean -->
     <bean id="caveRepositoryMBean" class="org.apache.karaf.cave.server.management.internal.CaveRepositoryMBeanImpl">
         <property name="caveRepositoryService" ref="caveRepositoryService"/>
     </bean>
-
-    <bean id="mbeanRegistrer" class="org.apache.karaf.management.MBeanRegistrer">
-        <property name="mbeans">
-            <map>
-                <entry value="org.apache.karaf.cave:type=repository,name=${karaf.name}"
key-ref="caveRepositoryMBean"/>
-            </map>
-        </property>
-    </bean>
+    <service ref="caveRepositoryMBean" auto-export="interfaces">
+        <service-properties>
+            <entry key="jmx.objectname" value="org.apache.karaf.cave:type=repository,name=$[karaf.name]"/>
+        </service-properties>
+    </service>
 
 </blueprint>
\ No newline at end of file


Mime
View raw message