diff --git a/README.md b/README.md index a3e6af9..d91273c 100644 --- a/README.md +++ b/README.md @@ -71,6 +71,11 @@ Starting the probe in an application server Changelog ========= +2016-08-25 +---------- +-- Added: Probe name added to property file. "name=xxx" The name the Probe will announce itself as... +-- Fixed: bug in Attribute Digester (org.apache.commons.digester3.Digester is Case sensitive... Rather Picky that one !!) + 2016-03-15 ---------- -- Fixed: Enables use of JMX Attribute Variables like: "[attribute].[Variable]" diff --git a/data/prtgjmx-sample.properties b/data/prtgjmx-sample.properties index 9abcd28..885e63f 100644 --- a/data/prtgjmx-sample.properties +++ b/data/prtgjmx-sample.properties @@ -4,9 +4,9 @@ guid= #key=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx key= -#key=JRTEST01 -#host=192.168.0.170 -host=192.168.0.172 +#----- +#name=Probe Name to announce to PRTG, Default("HostName + [JMXMiniProbe]") +#name= #port=8080 #webprotocol=https webprotocol=http diff --git a/profiles/Saved/JMXMBeans_PPas11_JMX1.7.xml b/profiles/Saved/JMXMBeans_PPas11_JMX1.7.xml new file mode 100644 index 0000000..cafe45d --- /dev/null +++ b/profiles/Saved/JMXMBeans_PPas11_JMX1.7.xml @@ -0,0 +1,2274 @@ + + + + JMImplementation:type=MBeanServerDelegate + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + JMImplementation:type=MBeanServerDelegate + + Represents the MBean server from the management point of view. + + Class Name:javax.management.MBeanServerDelegate + + + ImplementationName + + The JMX implementation name (the name of this product) + + type=java.lang.String,unit=COUNT; Value=JMX + + + true + + + ImplementationVendor + + the JMX implementation vendor (the vendor of this product). + + type=java.lang.String,unit=COUNT; Value=Oracle Corporation + + + true + + + ImplementationVersion + + The JMX implementation version (the version of this product). + + type=java.lang.String,unit=COUNT; Value=1.7.0_91-b15 + + + true + + + MBeanServerId + + The MBean server agent identification + + type=java.lang.String,unit=COUNT; Value=stuppas11.stu.adml_1457975251743 + + + true + + + SpecificationName + + The full name of the JMX specification implemented by this product. + + type=java.lang.String,unit=COUNT; Value=Java Management Extensions + + + true + + + SpecificationVendor + + The vendor of the JMX specification implemented by this product. + + type=java.lang.String,unit=COUNT; Value=Oracle Corporation + + + true + + + SpecificationVersion + + The version of the JMX specification implemented by this product. + + type=java.lang.String,unit=COUNT; Value=1.4 + + + true + + + + + + + com.paessler.prtg.jmx.mbean.PRTGBean:name=JMXMiniProbe + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + com.paessler.prtg.jmx.mbean.PRTGBean:name=JMXMiniProbe + + JMX: PRTG JMXMiniProbe statistics + + Class Name:com.paessler.prtg.jmx.mbean.PRTGInterface + + + AvgExecutionTime + + AvgExecutionTime, Average query Execution Time[ms]. + + type=java.lang.long,unit=COUNT; Value=0 + + + true + + + AvgSenorCreationTime + + AvgSenorCreationTime, Average sensor creation Execution. + + type=java.lang.long,unit=COUNT; Value=0 + + + true + + + AvgUploadTime + + avgUploadTime, Average time to upload data Time[ms]. + + type=java.lang.long,unit=COUNT; Value=0 + + + true + + + QueryCount + + QueryCount, Number of queries run. + + type=java.lang.long,unit=COUNT; Value=0 + + + true + + + sensorCount + + SensorCount, Number of sensors. + + type=java.lang.int,unit=COUNT; Value=No such attribute: sensorCount + + + true + + + + + + + com.sun.management:type=HotSpotDiagnostic + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + com.sun.management:type=HotSpotDiagnostic + + Information on the management interface of the MBean + + Class Name:sun.management.HotSpotDiagnostic + + + DiagnosticOptions + + DiagnosticOptions + + type=[Ljavax.management.openmbean.CompositeData;,unit=COUNT; Value=[Ljavax.management.openmbean.CompositeData;@1fc202e5 + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=com.sun.management:type=HotSpotDiagnostic + + + true + + + + + + + java.lang:type=ClassLoading + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=ClassLoading + + Information on the management interface of the MBean + + Class Name:sun.management.ClassLoadingImpl + + + LoadedClassCount + + LoadedClassCount + + type=int,unit=COUNT; Value=1448 + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=ClassLoading + + + true + + + TotalLoadedClassCount + + TotalLoadedClassCount + + type=long,unit=COUNT; Value=1448 + + + true + + + UnloadedClassCount + + UnloadedClassCount + + type=long,unit=COUNT; Value=0 + + + true + + + Verbose + + Verbose + + type=boolean,unit=COUNT; Value=false + + + true + + + + + + + java.lang:type=Compilation + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=Compilation + + Information on the management interface of the MBean + + Class Name:sun.management.CompilationImpl + + + CompilationTimeMonitoringSupported + + CompilationTimeMonitoringSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=HotSpot 64-Bit Tiered Compilers + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=Compilation + + + true + + + TotalCompilationTime + + TotalCompilationTime + + type=long,unit=COUNT; Value=436 + + + true + + + + + + + java.lang:type=GarbageCollector,name=PS MarkSweep + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=GarbageCollector,name=PS MarkSweep + + Information on the management interface of the MBean + + Class Name:sun.management.GarbageCollectorImpl + + + CollectionCount + + CollectionCount + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionTime + + CollectionTime + + type=long,unit=COUNT; Value=0 + + + true + + + LastGcInfo + + LastGcInfo + + type=javax.management.openmbean.CompositeData,unit=COUNT + + + true + + + MemoryPoolNames + + MemoryPoolNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@7c18d288 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=PS MarkSweep + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=GarbageCollector,name=PS MarkSweep + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=GarbageCollector,name=PS Scavenge + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=GarbageCollector,name=PS Scavenge + + Information on the management interface of the MBean + + Class Name:sun.management.GarbageCollectorImpl + + + CollectionCount + + CollectionCount + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionTime + + CollectionTime + + type=long,unit=COUNT; Value=0 + + + true + + + LastGcInfo + + LastGcInfo + + type=javax.management.openmbean.CompositeData,unit=COUNT + + + true + + + MemoryPoolNames + + MemoryPoolNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@417cc8df + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=PS Scavenge + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=GarbageCollector,name=PS Scavenge + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=Memory + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=Memory + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryImpl + + + HeapMemoryUsage + + HeapMemoryUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=157286400, init=164129088, max=2335703040, used=19125776}) + + + true + + + NonHeapMemoryUsage + + NonHeapMemoryUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=24576000, init=24576000, max=136314880, used=9236496}) + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=Memory + + + true + + + ObjectPendingFinalizationCount + + ObjectPendingFinalizationCount + + type=int,unit=COUNT; Value=0 + + + true + + + Verbose + + Verbose + + type=boolean,unit=COUNT; Value=false + + + true + + + + + + + java.lang:type=MemoryManager,name=CodeCacheManager + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=MemoryManager,name=CodeCacheManager + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryManagerImpl + + + MemoryPoolNames + + MemoryPoolNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@3ab62081 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=CodeCacheManager + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=MemoryManager,name=CodeCacheManager + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=MemoryPool,name=Code Cache + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=MemoryPool,name=Code Cache + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryPoolImpl + + + CollectionUsage + + CollectionUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT + + + true + + + CollectionUsageThreshold + + CollectionUsageThreshold + + type=long,unit=COUNT; Value=java.lang.UnsupportedOperationException: CollectionUsage threshold is not supported + + + true + + + CollectionUsageThresholdCount + + CollectionUsageThresholdCount + + type=long,unit=COUNT; Value=java.lang.UnsupportedOperationException: CollectionUsage threshold is not supported + + + true + + + CollectionUsageThresholdExceeded + + CollectionUsageThresholdExceeded + + type=boolean,unit=COUNT; Value=java.lang.UnsupportedOperationException: CollectionUsage threshold is not supported + + + true + + + CollectionUsageThresholdSupported + + CollectionUsageThresholdSupported + + type=boolean,unit=COUNT; Value=false + + + true + + + MemoryManagerNames + + MemoryManagerNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@b101344 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=Code Cache + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=MemoryPool,name=Code Cache + + + true + + + PeakUsage + + PeakUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=2555904, init=2555904, max=50331648, used=605952}) + + + true + + + Type + + Type + + type=java.lang.String,unit=COUNT; Value=NON_HEAP + + + true + + + Usage + + Usage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=2555904, init=2555904, max=50331648, used=598208}) + + + true + + + UsageThreshold + + UsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + UsageThresholdCount + + UsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + UsageThresholdExceeded + + UsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + UsageThresholdSupported + + UsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=MemoryPool,name=PS Eden Space + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=MemoryPool,name=PS Eden Space + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryPoolImpl + + + CollectionUsage + + CollectionUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=0, init=41418752, max=862453760, used=0}) + + + true + + + CollectionUsageThreshold + + CollectionUsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdCount + + CollectionUsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdExceeded + + CollectionUsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + CollectionUsageThresholdSupported + + CollectionUsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + MemoryManagerNames + + MemoryManagerNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@52e530d5 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=PS Eden Space + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=MemoryPool,name=PS Eden Space + + + true + + + PeakUsage + + PeakUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=41418752, init=41418752, max=862453760, used=20262968}) + + + true + + + Type + + Type + + type=java.lang.String,unit=COUNT; Value=HEAP + + + true + + + Usage + + Usage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=41418752, init=41418752, max=862453760, used=20262968}) + + + true + + + UsageThreshold + + UsageThreshold + + type=long,unit=COUNT; Value=java.lang.UnsupportedOperationException: Usage threshold is not supported + + + true + + + UsageThresholdCount + + UsageThresholdCount + + type=long,unit=COUNT; Value=java.lang.UnsupportedOperationException: Usage threshold is not supported + + + true + + + UsageThresholdExceeded + + UsageThresholdExceeded + + type=boolean,unit=COUNT; Value=java.lang.UnsupportedOperationException: Usage threshold is not supported + + + true + + + UsageThresholdSupported + + UsageThresholdSupported + + type=boolean,unit=COUNT; Value=false + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=MemoryPool,name=PS Old Gen + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=MemoryPool,name=PS Old Gen + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryPoolImpl + + + CollectionUsage + + CollectionUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=0, init=109051904, max=1751646208, used=0}) + + + true + + + CollectionUsageThreshold + + CollectionUsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdCount + + CollectionUsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdExceeded + + CollectionUsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + CollectionUsageThresholdSupported + + CollectionUsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + MemoryManagerNames + + MemoryManagerNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@696add0e + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=PS Old Gen + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=MemoryPool,name=PS Old Gen + + + true + + + PeakUsage + + PeakUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=109051904, init=109051904, max=1751646208, used=0}) + + + true + + + Type + + Type + + type=java.lang.String,unit=COUNT; Value=HEAP + + + true + + + Usage + + Usage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=109051904, init=109051904, max=1751646208, used=0}) + + + true + + + UsageThreshold + + UsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + UsageThresholdCount + + UsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + UsageThresholdExceeded + + UsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + UsageThresholdSupported + + UsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=MemoryPool,name=PS Perm Gen + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=MemoryPool,name=PS Perm Gen + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryPoolImpl + + + CollectionUsage + + CollectionUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=0, init=22020096, max=85983232, used=0}) + + + true + + + CollectionUsageThreshold + + CollectionUsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdCount + + CollectionUsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdExceeded + + CollectionUsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + CollectionUsageThresholdSupported + + CollectionUsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + MemoryManagerNames + + MemoryManagerNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@f631ab6 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=PS Perm Gen + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=MemoryPool,name=PS Perm Gen + + + true + + + PeakUsage + + PeakUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=22020096, init=22020096, max=85983232, used=8643664}) + + + true + + + Type + + Type + + type=java.lang.String,unit=COUNT; Value=NON_HEAP + + + true + + + Usage + + Usage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=22020096, init=22020096, max=85983232, used=8643664}) + + + true + + + UsageThreshold + + UsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + UsageThresholdCount + + UsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + UsageThresholdExceeded + + UsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + UsageThresholdSupported + + UsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=MemoryPool,name=PS Survivor Space + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=MemoryPool,name=PS Survivor Space + + Information on the management interface of the MBean + + Class Name:sun.management.MemoryPoolImpl + + + CollectionUsage + + CollectionUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=0, init=6815744, max=6815744, used=0}) + + + true + + + CollectionUsageThreshold + + CollectionUsageThreshold + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdCount + + CollectionUsageThresholdCount + + type=long,unit=COUNT; Value=0 + + + true + + + CollectionUsageThresholdExceeded + + CollectionUsageThresholdExceeded + + type=boolean,unit=COUNT; Value=false + + + true + + + CollectionUsageThresholdSupported + + CollectionUsageThresholdSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + MemoryManagerNames + + MemoryManagerNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@435792a0 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=PS Survivor Space + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=MemoryPool,name=PS Survivor Space + + + true + + + PeakUsage + + PeakUsage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=6815744, init=6815744, max=6815744, used=0}) + + + true + + + Type + + Type + + type=java.lang.String,unit=COUNT; Value=HEAP + + + true + + + Usage + + Usage + + type=javax.management.openmbean.CompositeData,unit=COUNT; Value=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.lang.management.MemoryUsage,items=((itemName=committed,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=init,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=max,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)),(itemName=used,itemType=javax.management.openmbean.SimpleType(name=java.lang.Long)))),contents={committed=6815744, init=6815744, max=6815744, used=0}) + + + true + + + UsageThreshold + + UsageThreshold + + type=long,unit=COUNT; Value=java.lang.UnsupportedOperationException: Usage threshold is not supported + + + true + + + UsageThresholdCount + + UsageThresholdCount + + type=long,unit=COUNT; Value=java.lang.UnsupportedOperationException: Usage threshold is not supported + + + true + + + UsageThresholdExceeded + + UsageThresholdExceeded + + type=boolean,unit=COUNT; Value=java.lang.UnsupportedOperationException: Usage threshold is not supported + + + true + + + UsageThresholdSupported + + UsageThresholdSupported + + type=boolean,unit=COUNT; Value=false + + + true + + + Valid + + Valid + + type=boolean,unit=COUNT; Value=true + + + true + + + + + + + java.lang:type=OperatingSystem + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=OperatingSystem + + Information on the management interface of the MBean + + Class Name:com.sun.management.UnixOperatingSystem + + + Arch + + Arch + + type=java.lang.String,unit=COUNT; Value=amd64 + + + true + + + AvailableProcessors + + AvailableProcessors + + type=int,unit=COUNT; Value=8 + + + true + + + CommittedVirtualMemorySize + + CommittedVirtualMemorySize + + type=long,unit=COUNT; Value=4293480448 + + + true + + + FreePhysicalMemorySize + + FreePhysicalMemorySize + + type=long,unit=COUNT; Value=1230577664 + + + true + + + FreeSwapSpaceSize + + FreeSwapSpaceSize + + type=long,unit=COUNT; Value=2115387392 + + + true + + + MaxFileDescriptorCount + + MaxFileDescriptorCount + + type=long,unit=COUNT; Value=500000 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=Linux + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=OperatingSystem + + + true + + + OpenFileDescriptorCount + + OpenFileDescriptorCount + + type=long,unit=COUNT; Value=32 + + + true + + + ProcessCpuLoad + + ProcessCpuLoad + + type=double,unit=COUNT; Value=8.916457021876531E-8 + + + true + + + ProcessCpuTime + + ProcessCpuTime + + type=long,unit=COUNT; Value=1200000000 + + + true + + + SystemCpuLoad + + SystemCpuLoad + + type=double,unit=COUNT; Value=0.008474343410607045 + + + true + + + SystemLoadAverage + + SystemLoadAverage + + type=double,unit=COUNT; Value=0.38 + + + true + + + TotalPhysicalMemorySize + + TotalPhysicalMemorySize + + type=long,unit=COUNT; Value=10504261632 + + + true + + + TotalSwapSpaceSize + + TotalSwapSpaceSize + + type=long,unit=COUNT; Value=2147475456 + + + true + + + Version + + Version + + type=java.lang.String,unit=COUNT; Value=2.6.32-431.23.3.el6.x86_64 + + + true + + + + + + + java.lang:type=Runtime + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=Runtime + + Information on the management interface of the MBean + + Class Name:sun.management.RuntimeImpl + + + BootClassPath + + BootClassPath + + type=java.lang.String,unit=COUNT; Value=/data/stu/java/jdk1.7.0_91/jre/lib/resources.jar:/data/stu/java/jdk1.7.0_91/jre/lib/rt.jar:/data/stu/java/jdk1.7.0_91/jre/lib/sunrsasign.jar:/data/stu/java/jdk1.7.0_91/jre/lib/jsse.jar:/data/stu/java/jdk1.7.0_91/jre/lib/jce.jar:/data/stu/java/jdk1.7.0_91/jre/lib/charsets.jar:/data/stu/java/jdk1.7.0_91/jre/lib/jfr.jar:/data/stu/java/jdk1.7.0_91/jre/classes + + + true + + + BootClassPathSupported + + BootClassPathSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + ClassPath + + ClassPath + + type=java.lang.String,unit=COUNT; Value=/data_shared/sup_jmx_JLO/JMXProbe/etc:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/javax.servlet-api-3.1.0.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-cli-1.2.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-codec-1.6.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-logging-1.1.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/gson-2.2.2.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpclient-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpclient-cache-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpcore-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpmime-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-digester3-3.2-with-deps.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/cglib-2.2.2.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/asm-3.3.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-beanutils-1.8.3.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-lang3-3.4.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/snmp4j-2.3.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/log4j-1.2.14.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/snmp4j-agent-2.3.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/platform-3.5.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/jna-3.5.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/icmp4j-16.0.1017-1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/sblim-cim-client2-2.2.5.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/dnsjava-2.1.7.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/JMXMiniProbe-1.0.jar + + + true + + + InputArguments + + InputArguments + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@420d3967 + + + true + + + LibraryPath + + LibraryPath + + type=java.lang.String,unit=COUNT; Value=/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib + + + true + + + ManagementSpecVersion + + ManagementSpecVersion + + type=java.lang.String,unit=COUNT; Value=1.2 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=30410@stuppas11.stu.adml + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=Runtime + + + true + + + SpecName + + SpecName + + type=java.lang.String,unit=COUNT; Value=Java Virtual Machine Specification + + + true + + + SpecVendor + + SpecVendor + + type=java.lang.String,unit=COUNT; Value=Oracle Corporation + + + true + + + SpecVersion + + SpecVersion + + type=java.lang.String,unit=COUNT; Value=1.7 + + + true + + + StartTime + + StartTime + + type=long,unit=COUNT; Value=1457975250095 + + + true + + + SystemProperties + + SystemProperties + + type=javax.management.openmbean.TabularData,unit=COUNT; Value=javax.management.openmbean.TabularDataSupport(tabularType=javax.management.openmbean.TabularType(name=java.util.Map<java.lang.String, java.lang.String>,rowType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),indexNames=(key)),contents={[java.vm.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.version, value=24.91-b03}), [java.vendor.url]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vendor.url, value=http://java.oracle.com/}), [sun.jnu.encoding]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.jnu.encoding, value=UTF-8}), [java.vm.info]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.info, value=mixed mode}), [user.dir]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=user.dir, value=/data_shared/sup_jmx_JLO/JMXProbe/bin}), [sun.cpu.isalist]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.cpu.isalist, value=}), [java.awt.graphicsenv]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.awt.graphicsenv, value=sun.awt.X11GraphicsEnvironment}), [sun.os.patch.level]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.os.patch.level, value=unknown}), [java.io.tmpdir]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.io.tmpdir, value=/tmp}), [user.home]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=user.home, value=/home/ocb}), [java.awt.printerjob]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.awt.printerjob, value=sun.print.PSPrinterJob}), [java.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.version, value=1.7.0_91}), [file.encoding.pkg]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=file.encoding.pkg, value=sun.io}), [java.vendor.url.bug]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vendor.url.bug, value=http://bugreport.sun.com/bugreport/}), [file.encoding]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=file.encoding, value=UTF-8}), [line.separator]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=line.separator, value= +}), [app.home]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=app.home, value=/data_shared/sup_jmx_JLO/JMXProbe}), [sun.java.command]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.java.command, value=com.paessler.prtg.jmx.DaemonMain}), [java.vm.specification.vendor]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.specification.vendor, value=Oracle Corporation}), [java.vm.vendor]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.vendor, value=Oracle Corporation}), [app.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=app.name, value=runJMXMiniProbe}), [java.class.path]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.class.path, value=/data_shared/sup_jmx_JLO/JMXProbe/etc:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/javax.servlet-api-3.1.0.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-cli-1.2.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-codec-1.6.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-logging-1.1.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/gson-2.2.2.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpclient-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpclient-cache-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpcore-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/httpmime-4.4.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-digester3-3.2-with-deps.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/cglib-2.2.2.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/asm-3.3.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-beanutils-1.8.3.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/commons-lang3-3.4.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/snmp4j-2.3.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/log4j-1.2.14.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/snmp4j-agent-2.3.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/platform-3.5.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/jna-3.5.1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/icmp4j-16.0.1017-1.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/sblim-cim-client2-2.2.5.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/dnsjava-2.1.7.jar:/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib/JMXMiniProbe-1.0.jar}), [sun.io.unicode.encoding]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.io.unicode.encoding, value=UnicodeLittle}), [os.arch]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=os.arch, value=amd64}), [app.repo]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=app.repo, value=/data_shared/sup_jmx_JLO/JMXProbe/WEB-INF/lib}), [user.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=user.name, value=ocb}), [user.language]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=user.language, value=fr}), [java.runtime.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.runtime.version, value=1.7.0_91-b15}), [sun.boot.class.path]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.boot.class.path, value=/data/stu/java/jdk1.7.0_91/jre/lib/resources.jar:/data/stu/java/jdk1.7.0_91/jre/lib/rt.jar:/data/stu/java/jdk1.7.0_91/jre/lib/sunrsasign.jar:/data/stu/java/jdk1.7.0_91/jre/lib/jsse.jar:/data/stu/java/jdk1.7.0_91/jre/lib/jce.jar:/data/stu/java/jdk1.7.0_91/jre/lib/charsets.jar:/data/stu/java/jdk1.7.0_91/jre/lib/jfr.jar:/data/stu/java/jdk1.7.0_91/jre/classes}), [sun.cpu.endian]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.cpu.endian, value=little}), [awt.toolkit]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=awt.toolkit, value=sun.awt.X11.XToolkit}), [sun.boot.library.path]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.boot.library.path, value=/data/stu/java/jdk1.7.0_91/jre/lib/amd64}), [java.vm.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.name, value=Java HotSpot(TM) 64-Bit Server VM}), [java.home]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.home, value=/data/stu/java/jdk1.7.0_91/jre}), [app.pid]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=app.pid, value=30410}), [java.endorsed.dirs]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.endorsed.dirs, value=/data/stu/java/jdk1.7.0_91/jre/lib/endorsed}), [basedir]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=basedir, value=/data_shared/sup_jmx_JLO/JMXProbe}), [sun.management.compiler]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.management.compiler, value=HotSpot 64-Bit Tiered Compilers}), [java.runtime.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.runtime.name, value=Java(TM) SE Runtime Environment}), [java.library.path]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.library.path, value=/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib}), [file.separator]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=file.separator, value=/}), [java.specification.vendor]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.specification.vendor, value=Oracle Corporation}), [java.vm.specification.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.specification.version, value=1.7}), [sun.java.launcher]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.java.launcher, value=SUN_STANDARD}), [user.timezone]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=user.timezone, value=}), [os.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=os.name, value=Linux}), [path.separator]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=path.separator, value=:}), [java.ext.dirs]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.ext.dirs, value=/data/stu/java/jdk1.7.0_91/jre/lib/ext:/usr/java/packages/lib/ext}), [sun.arch.data.model]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=sun.arch.data.model, value=64}), [java.specification.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.specification.name, value=Java Platform API Specification}), [os.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=os.version, value=2.6.32-431.23.3.el6.x86_64}), [user.country]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=user.country, value=FR}), [java.class.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.class.version, value=51.0}), [java.vendor]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vendor, value=Oracle Corporation}), [java.vm.specification.name]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.vm.specification.name, value=Java Virtual Machine Specification}), [java.specification.version]=javax.management.openmbean.CompositeDataSupport(compositeType=javax.management.openmbean.CompositeType(name=java.util.Map<java.lang.String, java.lang.String>,items=((itemName=key,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)),(itemName=value,itemType=javax.management.openmbean.SimpleType(name=java.lang.String)))),contents={key=java.specification.version, value=1.7})}) + + + true + + + Uptime + + Uptime + + type=long,unit=COUNT; Value=1736 + + + true + + + VmName + + VmName + + type=java.lang.String,unit=COUNT; Value=Java HotSpot(TM) 64-Bit Server VM + + + true + + + VmVendor + + VmVendor + + type=java.lang.String,unit=COUNT; Value=Oracle Corporation + + + true + + + VmVersion + + VmVersion + + type=java.lang.String,unit=COUNT; Value=24.91-b03 + + + true + + + + + + + java.lang:type=Threading + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.lang:type=Threading + + Information on the management interface of the MBean + + Class Name:sun.management.ThreadImpl + + + AllThreadIds + + AllThreadIds + + type=[J,unit=COUNT; Value=[J@35b220a3 + + + true + + + CurrentThreadCpuTime + + CurrentThreadCpuTime + + type=long,unit=COUNT; Value=96709466 + + + true + + + CurrentThreadCpuTimeSupported + + CurrentThreadCpuTimeSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + CurrentThreadUserTime + + CurrentThreadUserTime + + type=long,unit=COUNT; Value=90000000 + + + true + + + DaemonThreadCount + + DaemonThreadCount + + type=int,unit=COUNT; Value=3 + + + true + + + ObjectMonitorUsageSupported + + ObjectMonitorUsageSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.lang:type=Threading + + + true + + + PeakThreadCount + + PeakThreadCount + + type=int,unit=COUNT; Value=5 + + + true + + + SynchronizerUsageSupported + + SynchronizerUsageSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + ThreadAllocatedMemoryEnabled + + ThreadAllocatedMemoryEnabled + + type=boolean,unit=COUNT; Value=true + + + true + + + ThreadAllocatedMemorySupported + + ThreadAllocatedMemorySupported + + type=boolean,unit=COUNT; Value=true + + + true + + + ThreadContentionMonitoringEnabled + + ThreadContentionMonitoringEnabled + + type=boolean,unit=COUNT; Value=false + + + true + + + ThreadContentionMonitoringSupported + + ThreadContentionMonitoringSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + ThreadCount + + ThreadCount + + type=int,unit=COUNT; Value=5 + + + true + + + ThreadCpuTimeEnabled + + ThreadCpuTimeEnabled + + type=boolean,unit=COUNT; Value=true + + + true + + + ThreadCpuTimeSupported + + ThreadCpuTimeSupported + + type=boolean,unit=COUNT; Value=true + + + true + + + TotalStartedThreadCount + + TotalStartedThreadCount + + type=long,unit=COUNT; Value=6 + + + true + + + + + + + java.nio:type=BufferPool,name=direct + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.nio:type=BufferPool,name=direct + + Information on the management interface of the MBean + + Class Name:sun.management.ManagementFactoryHelper$1 + + + Count + + Count + + type=long,unit=COUNT; Value=0 + + + true + + + MemoryUsed + + MemoryUsed + + type=long,unit=COUNT; Value=0 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=direct + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.nio:type=BufferPool,name=direct + + + true + + + TotalCapacity + + TotalCapacity + + type=long,unit=COUNT; Value=0 + + + true + + + + + + + java.nio:type=BufferPool,name=mapped + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.nio:type=BufferPool,name=mapped + + Information on the management interface of the MBean + + Class Name:sun.management.ManagementFactoryHelper$1 + + + Count + + Count + + type=long,unit=COUNT; Value=0 + + + true + + + MemoryUsed + + MemoryUsed + + type=long,unit=COUNT; Value=0 + + + true + + + Name + + Name + + type=java.lang.String,unit=COUNT; Value=mapped + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.nio:type=BufferPool,name=mapped + + + true + + + TotalCapacity + + TotalCapacity + + type=long,unit=COUNT; Value=0 + + + true + + + + + + + java.util.logging:type=Logging + jmxsensor,mjjmxsensor + jmxsensor + + com.paessler.prtg.jmx.sensors.JMXSensor + + + + java.util.logging:type=Logging + + Information on the management interface of the MBean + + Class Name:sun.management.ManagementFactoryHelper$PlatformLoggingImpl + + + LoggerNames + + LoggerNames + + type=[Ljava.lang.String;,unit=COUNT; Value=[Ljava.lang.String;@5d6227a2 + + + true + + + ObjectName + + ObjectName + + type=javax.management.ObjectName,unit=COUNT; Value=java.util.logging:type=Logging + + + true + + + + + + diff --git a/src/com/paessler/prtg/jmx/Logger.java b/src/com/paessler/prtg/jmx/Logger.java index 361f4c4..2555aba 100644 --- a/src/com/paessler/prtg/jmx/Logger.java +++ b/src/com/paessler/prtg/jmx/Logger.java @@ -30,14 +30,25 @@ package com.paessler.prtg.jmx; +import java.io.PrintWriter; +import java.io.StringWriter; + import javax.servlet.ServletContext; +import com.paessler.prtg.util.StringUtility; + // TODO This is very lazy public class Logger { protected static ServletContext context; public static void initLogger(ServletContext srvrlcontext){ context = srvrlcontext; } + public static void log(String message, Exception e) { + StringWriter target = new StringWriter(); + target.append(message+StringUtility.NewLine); + e.printStackTrace(new PrintWriter(target)); + log(target.toString()); + } public static void log(String message) { if (context != null) { context.log(message); diff --git a/src/com/paessler/prtg/jmx/ProbeContext.java b/src/com/paessler/prtg/jmx/ProbeContext.java index 3ebec09..09961cf 100644 --- a/src/com/paessler/prtg/jmx/ProbeContext.java +++ b/src/com/paessler/prtg/jmx/ProbeContext.java @@ -60,6 +60,7 @@ import com.paessler.prtg.jmx.sensors.profile.ProfileFactory; import com.paessler.prtg.jmx.sensors.profile.Profiles; import com.paessler.prtg.util.ClassUtility; +import com.paessler.prtg.util.SystemUtility; import com.paessler.prtg.util.snmp.SNMPUtil; //import sun.org.mozilla.javascript.internal.ast.TryStatement; @@ -71,6 +72,7 @@ public class ProbeContext { public static final String HOST_STRING = "host"; public static final String HOST_GUID = "guid"; + public static final String PROBE_NAME = "name"; public static final String KEY_STRING = "key"; public static final String SENSORPROFILE_STRING = "sensorprofile"; public static final String DUMPJMXRMI_STRING = "dumpjmx.rmistring"; @@ -197,6 +199,13 @@ public Properties loadProperties(String configPath){ // ------------------------------------ // BEGIN Optional if(!isErrorStatus()) { + + tmp = settings.getProperty(ProbeContext.PROBE_NAME); + if (tmp != null) { + setProbeName(tmp); + tmp = null; + } else + { setProbeName(SystemUtility.getHostName() + " [JMXMiniProbe]"); } tmp = settings.getProperty(ProbeContext.SENSORPROFILE_STRING); if (tmp != null) { diff --git a/src/com/paessler/prtg/jmx/network/NetworkWrapper.java b/src/com/paessler/prtg/jmx/network/NetworkWrapper.java index ae33cc8..112ed00 100644 --- a/src/com/paessler/prtg/jmx/network/NetworkWrapper.java +++ b/src/com/paessler/prtg/jmx/network/NetworkWrapper.java @@ -105,7 +105,9 @@ public static void post(String url, String Data) throws IOException { public static void post(String url, String data, int timeout) throws IOException { DefaultHttpClient httpClient = getClient(timeout); - Logger.log("Uploading " + data + " to " + url); +// if(context.getDebugLevel() > 0){ +// Logger.log("Uploading " + data + " to " + url); +// } HttpPost post = new HttpPost(url); post.setEntity(new StringEntity(data)); post.setHeader("Accept", "application/json"); diff --git a/src/com/paessler/prtg/jmx/sensors/JMXSensor.java b/src/com/paessler/prtg/jmx/sensors/JMXSensor.java index c621cd8..e2dda3d 100644 --- a/src/com/paessler/prtg/jmx/sensors/JMXSensor.java +++ b/src/com/paessler/prtg/jmx/sensors/JMXSensor.java @@ -143,15 +143,22 @@ public DataResponse go() { error.setMessage("Failed to connect JMX Server (Service URL: " + rmiString + ")"); return error; } - response = getResponses(mbsc); } catch (Exception e) { - e.printStackTrace(); + String errMessage = e.getMessage() + " (Service URL: " + rmiString + ")"; + if(e instanceof java.io.IOException) + { + errMessage = "Connection/SSL Problem; " + errMessage; + Logger.log(errMessage); + } else + { + Logger.log(errMessage, e); + } DataError error = new DataError(sensorid, getSensorName()); error.setCode(-1); error.setError("Exception"); - error.setMessage(e.getMessage() + " (Service URL: " + rmiString + ")"); + error.setMessage(errMessage); response = error; } finally { if (mbsch != null) { diff --git a/src/com/paessler/prtg/jmx/sensors/jmx/JMXUtils.java b/src/com/paessler/prtg/jmx/sensors/jmx/JMXUtils.java index 69b9b95..8ccb129 100644 --- a/src/com/paessler/prtg/jmx/sensors/jmx/JMXUtils.java +++ b/src/com/paessler/prtg/jmx/sensors/jmx/JMXUtils.java @@ -58,6 +58,7 @@ import org.apache.commons.cli.Options; import org.apache.commons.cli.PosixParser; +import com.paessler.prtg.jmx.Logger; import com.paessler.prtg.jmx.mbean.PRTGInterface; import com.paessler.prtg.jmx.sensors.JMXSensor; import com.paessler.prtg.jmx.sensors.profile.Entry; @@ -297,7 +298,7 @@ public static boolean dumpJMXToFile(String outputfile, String rmiString, String } } catch (IOException e) { // TODO Auto-generated catch block - System.out.println("Cought Exception while Connecting to ["+rmiString+"] "+e.getMessage()); + Logger.log("Cought Exception while Connecting to ["+rmiString+"] "+e.getMessage()); } String xml = null; if(mbsc != null){ @@ -306,14 +307,15 @@ public static boolean dumpJMXToFile(String outputfile, String rmiString, String prof = getBeanProfiles(mbsc, JMXSensorDefinition.KIND, JMXSensorDefinition.TAG, includeselfie); } catch (IOException e1) { // TODO Auto-generated catch block - e1.printStackTrace(); + Logger.log("Cought Exception while dumpJMXToFile ", e1); + } if(prof != null){ xml = ProfileFactory.toXML(prof); if(xml != null){ if(outputfile != null){ File ofn = new File(outputfile); - System.out.println("Outputting XML to ["+ofn.getAbsolutePath()+"] "); + Logger.log("Outputting XML to ["+ofn.getAbsolutePath()+"] "); OutputStream os = null; try { os = new FileOutputStream(ofn); @@ -336,7 +338,7 @@ public static boolean dumpJMXToFile(String outputfile, String rmiString, String } } // finally } else {// if os - System.out.println(xml); + Logger.log(xml); } } } @@ -344,7 +346,7 @@ public static boolean dumpJMXToFile(String outputfile, String rmiString, String mbsch.close(); } else { - System.out.println("No Connection to JMX Server"); + Logger.log("No Connection to JMX Server"); } return retVal; } @@ -384,7 +386,7 @@ public static void main(String[] args) { // Profiles prof = loadProfile(null, "W:/Paessler/java/JMXMiniProbe/data/profiles/jmx/Tomcat.xml"); if(!dumpJMXToFile(outputfile, rmiString, username, password, includeselfie)){ - System.out.println("Failed to dump JMX MBeans"); + Logger.log("Failed to dump JMX MBeans"); } // System.out.println(prof); } diff --git a/src/com/paessler/prtg/jmx/sensors/profile/Attribute.java b/src/com/paessler/prtg/jmx/sensors/profile/Attribute.java index 6f18868..6f4551c 100644 --- a/src/com/paessler/prtg/jmx/sensors/profile/Attribute.java +++ b/src/com/paessler/prtg/jmx/sensors/profile/Attribute.java @@ -274,7 +274,7 @@ public static Digester describe4Digester(Digester digester, String base) throws digester.addBeanPropertySetter( base+"/enabled", "enabled" ); digester.addBeanPropertySetter( base+"/unit", "unit" ); digester.addBeanPropertySetter( base+"/mode", "mode" ); - digester.addBeanPropertySetter( base+"/customunit", "customunit" ); + digester.addBeanPropertySetter( base+"/customunit", "customUnit" ); // digester.addCallMethod(base+"/unit", "setUnit", 1, new String[]{"java.lang.String"}); digester.addBeanPropertySetter( base+"/mpy", "mpy" ); diff --git a/src/com/paessler/prtg/jmx/tasks/TaskFetcherTask.java b/src/com/paessler/prtg/jmx/tasks/TaskFetcherTask.java index 4b17bca..040fbf9 100644 --- a/src/com/paessler/prtg/jmx/tasks/TaskFetcherTask.java +++ b/src/com/paessler/prtg/jmx/tasks/TaskFetcherTask.java @@ -101,8 +101,8 @@ public boolean sendAnnouncement(ProbeContext context){ retVal = true; reRunAnnouncement = false; } catch (HttpResponseException he) { + Logger.log(he.getLocalizedMessage()); if(he.getStatusCode() < 500){ - Logger.log(he.getLocalizedMessage()); Thread.sleep(10000*retryAttempts); } else{ retryAttempts = maxtries;