changeset 547:3d7b096dc162

Activate Thread plugin. PR 1107
author Mario Torre <neugens.limasoftware@gmail.com>
date Fri, 17 Aug 2012 13:13:47 +0200
parents 5ad8ad98f110
children e47c726e6e60
files client/heapdumper/src/main/java/com/redhat/thermostat/client/heap/HeapDumpController.java client/swing-components/pom.xml common/core/src/main/java/com/redhat/thermostat/common/MultipleServiceTracker.java distribution/config/bundles.properties distribution/config/osgi-export.properties distribution/pom.xml launcher/src/main/java/com/redhat/thermostat/launcher/internal/Activator.java pom.xml thread/pom.xml
diffstat 9 files changed, 105 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/client/heapdumper/src/main/java/com/redhat/thermostat/client/heap/HeapDumpController.java	Fri Aug 17 13:06:49 2012 +0200
+++ b/client/heapdumper/src/main/java/com/redhat/thermostat/client/heap/HeapDumpController.java	Fri Aug 17 13:13:47 2012 +0200
@@ -46,7 +46,6 @@
 import com.redhat.thermostat.client.heap.chart.OverviewChart;
 import com.redhat.thermostat.client.heap.cli.HeapDumperCommand;
 import com.redhat.thermostat.client.osgi.service.ApplicationService;
-import com.redhat.thermostat.client.osgi.service.BasicView;
 import com.redhat.thermostat.client.osgi.service.VmInformationServiceController;
 import com.redhat.thermostat.client.osgi.service.BasicView.Action;
 import com.redhat.thermostat.client.ui.UIComponent;
--- a/client/swing-components/pom.xml	Fri Aug 17 13:06:49 2012 +0200
+++ b/client/swing-components/pom.xml	Fri Aug 17 13:13:47 2012 +0200
@@ -55,6 +55,7 @@
             <Export-Package>
               com.redhat.thermostat.swing,
               com.redhat.thermostat.models,
+              com.redhat.thermostat.swing.models,
               com.redhat.thermostat.charts
             </Export-Package>
             <!-- Do not autogenerate uses clauses in Manifests -->
--- a/common/core/src/main/java/com/redhat/thermostat/common/MultipleServiceTracker.java	Fri Aug 17 13:06:49 2012 +0200
+++ b/common/core/src/main/java/com/redhat/thermostat/common/MultipleServiceTracker.java	Fri Aug 17 13:13:47 2012 +0200
@@ -58,7 +58,7 @@
 public class MultipleServiceTracker {
 
     public interface Action {
-        public void doIt(Map<Object, Object> services);
+        public void doIt(Map<String, Object> services);
     }
 
     class InternalServiceTrackerCustomizer implements ServiceTrackerCustomizer {
@@ -103,12 +103,12 @@
             }
         }
 
-        private Object getServiceClassName(ServiceReference reference) {
+        private String getServiceClassName(ServiceReference reference) {
             return ((String[]) reference.getProperty(OBJECT_CLASS))[0];
         }
     }
 
-    private Map<Object, Object> services;
+    private Map<String, Object> services;
     private Collection<ServiceTracker> trackers;
     private Action action;
     private BundleContext context;
@@ -143,7 +143,7 @@
     }
 
     private boolean allServicesReady() {
-        for (Entry<Object, Object> entry: services.entrySet()) {
+        for (Entry<String, Object> entry: services.entrySet()) {
             if (entry.getValue() == null) {
                 return false;
             }
--- a/distribution/config/bundles.properties	Fri Aug 17 13:06:49 2012 +0200
+++ b/distribution/config/bundles.properties	Fri Aug 17 13:13:47 2012 +0200
@@ -15,7 +15,11 @@
       thermostat-osgi-living-vm-filter-@project.version@.jar, \
       thermostat-osgi-memory-stats-panel-@project.version@.jar, \
       thermostat-swing-components-@project.version@.jar, \
-      thermostat-laf-@project.version@.jar
+      thermostat-laf-@project.version@.jar, \
+      thermostat-thread-collector-@project.version@.jar, \
+      thermostat-thread-client-swing-@project.version@.jar, \
+      thermostat-thread-client-controllers-@project.version@.jar, \
+      thermostat-thread-client-common-@project.version@.jar
 
 service = thermostat-agent-core-@project.version@.jar, \
           thermostat-osgi-process-handler-@project.version@.jar, \
--- a/distribution/config/osgi-export.properties	Fri Aug 17 13:06:49 2012 +0200
+++ b/distribution/config/osgi-export.properties	Fri Aug 17 13:13:47 2012 +0200
@@ -58,6 +58,7 @@
 com.sun.tools.hat.internal.model
 com.sun.tools.hat.internal.parser
 com.sun.tools.attach
+com.sun.management
 
 jline=2.5.0
 jline.console=2.5.0
--- a/distribution/pom.xml	Fri Aug 17 13:06:49 2012 +0200
+++ b/distribution/pom.xml	Fri Aug 17 13:13:47 2012 +0200
@@ -323,5 +323,28 @@
         <artifactId>thermostat-keyring</artifactId>
         <version>${project.version}</version>
     </dependency>
+    
+    <!--  thread plugin -->
+    <dependency>
+        <groupId>com.redhat.thermostat</groupId>
+        <artifactId>thermostat-thread-client-common</artifactId>
+        <version>${project.version}</version>
+    </dependency>
+    <dependency>
+        <groupId>com.redhat.thermostat</groupId>
+        <artifactId>thermostat-thread-client-controllers</artifactId>
+        <version>${project.version}</version>
+    </dependency>
+    <dependency>
+        <groupId>com.redhat.thermostat</groupId>
+        <artifactId>thermostat-thread-client-swing</artifactId>
+        <version>${project.version}</version>
+    </dependency>
+    <dependency>
+        <groupId>com.redhat.thermostat</groupId>
+        <artifactId>thermostat-thread-collector</artifactId>
+        <version>${project.version}</version>
+    </dependency>      
+  
   </dependencies>
 </project>
--- a/launcher/src/main/java/com/redhat/thermostat/launcher/internal/Activator.java	Fri Aug 17 13:06:49 2012 +0200
+++ b/launcher/src/main/java/com/redhat/thermostat/launcher/internal/Activator.java	Fri Aug 17 13:13:47 2012 +0200
@@ -60,7 +60,7 @@
             this.context = context;
         }
         @Override
-        public void doIt(Map<Object, Object> services) {
+        public void doIt(Map<String, Object> services) {
             
             ServiceReference reference = context.getServiceReference(OSGiRegistryService.class);
             OSGiRegistryService bundleService = (OSGiRegistryService) context.getService(reference);
--- a/pom.xml	Fri Aug 17 13:06:49 2012 +0200
+++ b/pom.xml	Fri Aug 17 13:13:47 2012 +0200
@@ -108,6 +108,7 @@
     <module>client</module>
     <module>unix-process-handler</module>
     <module>keyring</module>
+    <module>thread</module>
   </modules>
 
   <build>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/thread/pom.xml	Fri Aug 17 13:13:47 2012 +0200
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+
+ Copyright 2012 Red Hat, Inc.
+
+ This file is part of Thermostat.
+
+ Thermostat is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published
+ by the Free Software Foundation; either version 2, or (at your
+ option) any later version.
+
+ Thermostat is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with Thermostat; see the file COPYING.  If not see
+ <http://www.gnu.org/licenses />.
+
+ Linking this code with other modules is making a combined work
+ based on this code.  Thus, the terms and conditions of the GNU
+ General Public License cover the whole combination.
+
+ As a special exception, the copyright holders of this code give
+ you permission to link this code with independent modules to
+ produce an executable, regardless of the license terms of these
+ independent modules, and to copy and distribute the resulting
+ executable under terms of your choice, provided that you also
+ meet, for each linked independent module, the terms and conditions
+ of the license of that module.  An independent module is a module
+ which is not derived from or based on this code.  If you modify
+ this code, you may extend this exception to your version of the
+ library, but you are not obligated to do so.  If you do not wish
+ to do so, delete this exception statement from your version.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>com.redhat.thermostat</groupId>
+    <artifactId>thermostat</artifactId>
+    <version>0.4.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>thermostat-thread</artifactId>
+  <packaging>pom</packaging>
+
+  <name>Thermostat Thread Analysis Plugins</name>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <modules>
+    <module>collector</module>
+    <module>client-common</module>
+    <module>client-swing</module>
+    <module>client-controllers</module>
+  </modules>
+
+</project>
+