You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by nc...@apache.org on 2013/11/01 22:14:10 UTC
[1/2] AMBARI-3669. Remove HBase port scanner and ha_status (ncole)
Updated Branches:
refs/heads/trunk 6b9ca4b41 -> c6c4e3483
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/test/resources/hbase_hbasemaster_jmx_2.json
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/resources/hbase_hbasemaster_jmx_2.json b/ambari-server/src/test/resources/hbase_hbasemaster_jmx_2.json
new file mode 100644
index 0000000..b5e63b8
--- /dev/null
+++ b/ambari-server/src/test/resources/hbase_hbasemaster_jmx_2.json
@@ -0,0 +1,840 @@
+{
+ "beans" : [ {
+ "name" : "Hadoop:service=HBase,name=StartupProgress",
+ "modelerType" : "StartupProgress",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "ElapsedTime" : 0,
+ "PercentComplete" : 0.0,
+ "LoadingFsImageCount" : 0,
+ "LoadingFsImageElapsedTime" : 0,
+ "LoadingFsImageTotal" : 0,
+ "LoadingFsImagePercentComplete" : 0.0,
+ "LoadingEditsCount" : 0,
+ "LoadingEditsElapsedTime" : 0,
+ "LoadingEditsTotal" : 0,
+ "LoadingEditsPercentComplete" : 0.0,
+ "SavingCheckpointCount" : 0,
+ "SavingCheckpointElapsedTime" : 0,
+ "SavingCheckpointTotal" : 0,
+ "SavingCheckpointPercentComplete" : 0.0,
+ "SafeModeCount" : 0,
+ "SafeModeElapsedTime" : 0,
+ "SafeModeTotal" : 0,
+ "SafeModePercentComplete" : 0.0
+ }, {
+ "name" : "java.lang:type=Memory",
+ "modelerType" : "sun.management.MemoryImpl",
+ "Verbose" : true,
+ "HeapMemoryUsage" : {
+ "committed" : 85000192,
+ "init" : 0,
+ "max" : 1071579136,
+ "used" : 21730952
+ },
+ "NonHeapMemoryUsage" : {
+ "committed" : 43581440,
+ "init" : 24313856,
+ "max" : 136314880,
+ "used" : 43121984
+ },
+ "ObjectPendingFinalizationCount" : 0
+ }, {
+ "name" : "Hadoop:service=HBase,name=Master,sub=AssignmentManger",
+ "modelerType" : "Master,sub=AssignmentManger",
+ "tag.Context" : "master",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "ritOldestAge" : 0,
+ "ritCount" : 0,
+ "BulkAssign_num_ops" : 1,
+ "BulkAssign_min" : 45,
+ "BulkAssign_max" : 45,
+ "BulkAssign_mean" : 45.0,
+ "BulkAssign_median" : 45.0,
+ "BulkAssign_75th_percentile" : 45.0,
+ "BulkAssign_95th_percentile" : 45.0,
+ "BulkAssign_99th_percentile" : 45.0,
+ "ritCountOverThreshold" : 0,
+ "Assign_num_ops" : 1,
+ "Assign_min" : 126,
+ "Assign_max" : 126,
+ "Assign_mean" : 126.0,
+ "Assign_median" : 126.0,
+ "Assign_75th_percentile" : 126.0,
+ "Assign_95th_percentile" : 126.0,
+ "Assign_99th_percentile" : 126.0
+ }, {
+ "name" : "Hadoop:service=HBase,name=MetricsSystem,sub=Control",
+ "modelerType" : "org.apache.hadoop.metrics2.impl.MetricsSystemImpl"
+ }, {
+ "name" : "Hadoop:service=HBase,name=UgiMetrics",
+ "modelerType" : "UgiMetrics",
+ "tag.Context" : "ugi",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "LoginSuccessNumOps" : 0,
+ "LoginSuccessAvgTime" : 0.0,
+ "LoginFailureNumOps" : 0,
+ "LoginFailureAvgTime" : 0.0
+ }, {
+ "name" : "java.lang:type=GarbageCollector,name=ConcurrentMarkSweep",
+ "modelerType" : "sun.management.GarbageCollectorImpl",
+ "LastGcInfo" : null,
+ "CollectionCount" : 0,
+ "CollectionTime" : 0,
+ "Name" : "ConcurrentMarkSweep",
+ "Valid" : true,
+ "MemoryPoolNames" : [ "Eden Space", "Survivor Space", "CMS Old Gen", "CMS Perm Gen" ]
+ }, {
+ "name" : "java.lang:type=Compilation",
+ "modelerType" : "sun.management.CompilationImpl",
+ "Name" : "HotSpot 64-Bit Tiered Compilers",
+ "CompilationTimeMonitoringSupported" : true,
+ "TotalCompilationTime" : 8007
+ }, {
+ "name" : "java.lang:type=MemoryPool,name=CMS Perm Gen",
+ "modelerType" : "sun.management.MemoryPoolImpl",
+ "Name" : "CMS Perm Gen",
+ "Type" : "NON_HEAP",
+ "Valid" : true,
+ "Usage" : {
+ "committed" : 41025536,
+ "init" : 21757952,
+ "max" : 85983232,
+ "used" : 40862208
+ },
+ "CollectionUsage" : {
+ "committed" : 0,
+ "init" : 21757952,
+ "max" : 85983232,
+ "used" : 0
+ },
+ "CollectionUsageThreshold" : 0,
+ "CollectionUsageThresholdCount" : 0,
+ "MemoryManagerNames" : [ "ConcurrentMarkSweep" ],
+ "PeakUsage" : {
+ "committed" : 41025536,
+ "init" : 21757952,
+ "max" : 85983232,
+ "used" : 40862208
+ },
+ "UsageThreshold" : 0,
+ "UsageThresholdCount" : 0,
+ "CollectionUsageThresholdExceeded" : true,
+ "CollectionUsageThresholdSupported" : true,
+ "UsageThresholdExceeded" : true,
+ "UsageThresholdSupported" : true
+ }, {
+ "name" : "java.lang:type=OperatingSystem",
+ "modelerType" : "com.sun.management.UnixOperatingSystem",
+ "MaxFileDescriptorCount" : 32768,
+ "OpenFileDescriptorCount" : 288,
+ "CommittedVirtualMemorySize" : 1797296128,
+ "FreePhysicalMemorySize" : 103264256,
+ "FreeSwapSpaceSize" : 2659946496,
+ "ProcessCpuTime" : 21320000000,
+ "TotalPhysicalMemorySize" : 1968824320,
+ "TotalSwapSpaceSize" : 2684346368,
+ "Name" : "Linux",
+ "Version" : "2.6.32-358.el6.x86_64",
+ "AvailableProcessors" : 1,
+ "Arch" : "amd64",
+ "SystemLoadAverage" : 0.25
+ }, {
+ "name" : "Hadoop:service=HBase,name=Master,sub=Balancer",
+ "modelerType" : "Master,sub=Balancer",
+ "tag.Context" : "master",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "BalancerCluster_num_ops" : 0,
+ "BalancerCluster_min" : 0,
+ "BalancerCluster_max" : 0,
+ "BalancerCluster_mean" : 0.0,
+ "BalancerCluster_median" : 0.0,
+ "BalancerCluster_75th_percentile" : 0.0,
+ "BalancerCluster_95th_percentile" : 0.0,
+ "BalancerCluster_99th_percentile" : 0.0,
+ "miscInvocationCount" : 2
+ }, {
+ "name" : "java.lang:type=MemoryManager,name=CodeCacheManager",
+ "modelerType" : "sun.management.MemoryManagerImpl",
+ "Name" : "CodeCacheManager",
+ "Valid" : true,
+ "MemoryPoolNames" : [ "Code Cache" ]
+ }, {
+ "name" : "java.lang:type=MemoryPool,name=CMS Old Gen",
+ "modelerType" : "sun.management.MemoryPoolImpl",
+ "Name" : "CMS Old Gen",
+ "Type" : "HEAP",
+ "Valid" : true,
+ "Usage" : {
+ "committed" : 65404928,
+ "init" : 65404928,
+ "max" : 1051983872,
+ "used" : 4429944
+ },
+ "CollectionUsage" : {
+ "committed" : 0,
+ "init" : 65404928,
+ "max" : 1051983872,
+ "used" : 0
+ },
+ "CollectionUsageThreshold" : 0,
+ "CollectionUsageThresholdCount" : 0,
+ "MemoryManagerNames" : [ "ConcurrentMarkSweep" ],
+ "PeakUsage" : {
+ "committed" : 65404928,
+ "init" : 65404928,
+ "max" : 1051983872,
+ "used" : 4429944
+ },
+ "UsageThreshold" : 0,
+ "UsageThresholdCount" : 0,
+ "CollectionUsageThresholdExceeded" : true,
+ "CollectionUsageThresholdSupported" : true,
+ "UsageThresholdExceeded" : true,
+ "UsageThresholdSupported" : true
+ }, {
+ "name" : "java.lang:type=GarbageCollector,name=Copy",
+ "modelerType" : "sun.management.GarbageCollectorImpl",
+ "LastGcInfo" : {
+ "GcThreadCount" : 1,
+ "duration" : 1,
+ "endTime" : 3272024,
+ "id" : 32,
+ "memoryUsageAfterGc" : [ {
+ "key" : "Eden Space",
+ "value" : {
+ "committed" : 17432576,
+ "init" : 17432576,
+ "max" : 17432576,
+ "used" : 0
+ }
+ }, {
+ "key" : "CMS Perm Gen",
+ "value" : {
+ "committed" : 41025536,
+ "init" : 21757952,
+ "max" : 85983232,
+ "used" : 40848832
+ }
+ }, {
+ "key" : "Code Cache",
+ "value" : {
+ "committed" : 2555904,
+ "init" : 2555904,
+ "max" : 50331648,
+ "used" : 2258816
+ }
+ }, {
+ "key" : "CMS Old Gen",
+ "value" : {
+ "committed" : 65404928,
+ "init" : 65404928,
+ "max" : 1051983872,
+ "used" : 4429944
+ }
+ }, {
+ "key" : "Survivor Space",
+ "value" : {
+ "committed" : 2162688,
+ "init" : 2162688,
+ "max" : 2162688,
+ "used" : 317240
+ }
+ } ],
+ "memoryUsageBeforeGc" : [ {
+ "key" : "Eden Space",
+ "value" : {
+ "committed" : 17432576,
+ "init" : 17432576,
+ "max" : 17432576,
+ "used" : 17432576
+ }
+ }, {
+ "key" : "CMS Perm Gen",
+ "value" : {
+ "committed" : 41025536,
+ "init" : 21757952,
+ "max" : 85983232,
+ "used" : 40848832
+ }
+ }, {
+ "key" : "Code Cache",
+ "value" : {
+ "committed" : 2555904,
+ "init" : 2555904,
+ "max" : 50331648,
+ "used" : 2258816
+ }
+ }, {
+ "key" : "CMS Old Gen",
+ "value" : {
+ "committed" : 65404928,
+ "init" : 65404928,
+ "max" : 1051983872,
+ "used" : 4414768
+ }
+ }, {
+ "key" : "Survivor Space",
+ "value" : {
+ "committed" : 2162688,
+ "init" : 2162688,
+ "max" : 2162688,
+ "used" : 259648
+ }
+ } ],
+ "startTime" : 3272023
+ },
+ "CollectionCount" : 32,
+ "CollectionTime" : 190,
+ "Name" : "Copy",
+ "Valid" : true,
+ "MemoryPoolNames" : [ "Eden Space", "Survivor Space" ]
+ }, {
+ "name" : "java.lang:type=MemoryPool,name=Code Cache",
+ "modelerType" : "sun.management.MemoryPoolImpl",
+ "Name" : "Code Cache",
+ "Type" : "NON_HEAP",
+ "Valid" : true,
+ "Usage" : {
+ "committed" : 2555904,
+ "init" : 2555904,
+ "max" : 50331648,
+ "used" : 2259776
+ },
+ "CollectionUsage" : null,
+ "MemoryManagerNames" : [ "CodeCacheManager" ],
+ "PeakUsage" : {
+ "committed" : 2555904,
+ "init" : 2555904,
+ "max" : 50331648,
+ "used" : 2270336
+ },
+ "UsageThreshold" : 0,
+ "UsageThresholdCount" : 0,
+ "CollectionUsageThresholdSupported" : false,
+ "UsageThresholdExceeded" : true,
+ "UsageThresholdSupported" : true
+ }, {
+ "name" : "Hadoop:service=HBase,name=JvmMetrics",
+ "modelerType" : "JvmMetrics",
+ "tag.Context" : "jvm",
+ "tag.ProcessName" : "IPC",
+ "tag.SessionId" : "",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "MemNonHeapUsedM" : 41.119453,
+ "MemNonHeapCommittedM" : 41.5625,
+ "MemHeapUsedM" : 19.991753,
+ "MemHeapCommittedM" : 81.0625,
+ "MemMaxM" : 1021.9375,
+ "GcCountCopy" : 32,
+ "GcTimeMillisCopy" : 190,
+ "GcCountConcurrentMarkSweep" : 0,
+ "GcTimeMillisConcurrentMarkSweep" : 0,
+ "GcCount" : 32,
+ "GcTimeMillis" : 190,
+ "ThreadsNew" : 0,
+ "ThreadsRunnable" : 18,
+ "ThreadsBlocked" : 0,
+ "ThreadsWaiting" : 71,
+ "ThreadsTimedWaiting" : 14,
+ "ThreadsTerminated" : 0,
+ "LogFatal" : 0,
+ "LogError" : 0,
+ "LogWarn" : 0,
+ "LogInfo" : 0
+ }, {
+ "name" : "java.lang:type=Runtime",
+ "modelerType" : "sun.management.RuntimeImpl",
+ "Name" : "12238@c6401.ambari.apache.org",
+ "ClassPath" : "/etc/hbase/conf:/usr/jdk64/jdk1.6.0_31/lib/tools.jar:/usr/lib/hbase/bin/..:/usr/lib/hbase/bin/../lib/activation-1.1.jar:/usr/lib/hbase/bin/../lib/aopalliance-1.0.jar:/usr/lib/hbase/bin/../lib/asm-3.1.jar:/usr/lib/hbase/bin/../lib/avro-1.7.4.jar:/usr/lib/hbase/bin/../lib/commons-beanutils-1.7.0.jar:/usr/lib/hbase/bin/../lib/commons-beanutils-core-1.8.0.jar:/usr/lib/hbase/bin/../lib/commons-cli-1.2.jar:/usr/lib/hbase/bin/../lib/commons-codec-1.7.jar:/usr/lib/hbase/bin/../lib/commons-collections-3.2.1.jar:/usr/lib/hbase/bin/../lib/commons-compress-1.4.1.jar:/usr/lib/hbase/bin/../lib/commons-configuration-1.6.jar:/usr/lib/hbase/bin/../lib/commons-daemon-1.0.13.jar:/usr/lib/hbase/bin/../lib/commons-digester-1.8.jar:/usr/lib/hbase/bin/../lib/commons-el-1.0.jar:/usr/lib/hbase/bin/../lib/commons-httpclient-3.1.jar:/usr/lib/hbase/bin/../lib/commons-io-2.4.jar:/usr/lib/hbase/bin/../lib/commons-lang-2.6.jar:/usr/lib/hbase/bin/../lib/commons-logging-1.1.1.jar:/usr/lib/hbase/b
in/../lib/commons-math-2.2.jar:/usr/lib/hbase/bin/../lib/commons-net-3.1.jar:/usr/lib/hbase/bin/../lib/core-3.1.1.jar:/usr/lib/hbase/bin/../lib/findbugs-annotations-1.3.9-1.jar:/usr/lib/hbase/bin/../lib/gmbal-api-only-3.0.0-b023.jar:/usr/lib/hbase/bin/../lib/grizzly-framework-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-http-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-http-server-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-http-servlet-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-rcm-2.1.2.jar:/usr/lib/hbase/bin/../lib/guava-12.0.1.jar:/usr/lib/hbase/bin/../lib/guice-3.0.jar:/usr/lib/hbase/bin/../lib/guice-servlet-3.0.jar:/usr/lib/hbase/bin/../lib/hbase-client-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-common-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-common-0.96.0.2.0.6.0-76-hadoop2-tests.jar:/usr/lib/hbase/bin/../lib/hbase-examples-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-hadoop2-compat-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib
/hbase/bin/../lib/hbase-hadoop-compat-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-it-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-it-0.96.0.2.0.6.0-76-hadoop2-tests.jar:/usr/lib/hbase/bin/../lib/hbase-prefix-tree-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-protocol-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-server-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-server-0.96.0.2.0.6.0-76-hadoop2-tests.jar:/usr/lib/hbase/bin/../lib/hbase-shell-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-testing-util-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-thrift-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/high-scale-lib-1.1.1.jar:/usr/lib/hbase/bin/../lib/htrace-core-2.01.jar:/usr/lib/hbase/bin/../lib/httpclient-4.1.3.jar:/usr/lib/hbase/bin/../lib/httpcore-4.1.3.jar:/usr/lib/hbase/bin/../lib/jackson-core-asl-1.8.8.jar:/usr/lib/hbase/bin/../lib/jackson-jaxrs-1.8.8.jar
:/usr/lib/hbase/bin/../lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hbase/bin/../lib/jackson-xc-1.8.8.jar:/usr/lib/hbase/bin/../lib/jamon-runtime-2.3.1.jar:/usr/lib/hbase/bin/../lib/jasper-compiler-5.5.23.jar:/usr/lib/hbase/bin/../lib/jasper-runtime-5.5.23.jar:/usr/lib/hbase/bin/../lib/javax.inject-1.jar:/usr/lib/hbase/bin/../lib/javax.servlet-3.1.jar:/usr/lib/hbase/bin/../lib/javax.servlet-api-3.0.1.jar:/usr/lib/hbase/bin/../lib/jaxb-api-2.2.2.jar:/usr/lib/hbase/bin/../lib/jaxb-impl-2.2.3-1.jar:/usr/lib/hbase/bin/../lib/jersey-client-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-core-1.8.jar:/usr/lib/hbase/bin/../lib/jersey-grizzly2-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-guice-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-json-1.8.jar:/usr/lib/hbase/bin/../lib/jersey-server-1.8.jar:/usr/lib/hbase/bin/../lib/jersey-test-framework-core-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-test-framework-grizzly2-1.9.jar:/usr/lib/hbase/bin/../lib/jets3t-0.6.1.jar:/usr/lib/hbase/bin/../lib/jettison-1.3.1.jar:
/usr/lib/hbase/bin/../lib/jetty-6.1.26.jar:/usr/lib/hbase/bin/../lib/jetty-sslengine-6.1.26.jar:/usr/lib/hbase/bin/../lib/jetty-util-6.1.26.jar:/usr/lib/hbase/bin/../lib/jruby-complete-1.6.8.jar:/usr/lib/hbase/bin/../lib/jsch-0.1.42.jar:/usr/lib/hbase/bin/../lib/jsp-2.1-6.1.14.jar:/usr/lib/hbase/bin/../lib/jsp-api-2.1-6.1.14.jar:/usr/lib/hbase/bin/../lib/jsp-api-2.1.jar:/usr/lib/hbase/bin/../lib/jsr305-1.3.9.jar:/usr/lib/hbase/bin/../lib/junit-4.11.jar:/usr/lib/hbase/bin/../lib/libthrift-0.9.0.jar:/usr/lib/hbase/bin/../lib/log4j-1.2.17.jar:/usr/lib/hbase/bin/../lib/management-api-3.0.0-b012.jar:/usr/lib/hbase/bin/../lib/metrics-core-2.1.2.jar:/usr/lib/hbase/bin/../lib/netty-3.6.6.Final.jar:/usr/lib/hbase/bin/../lib/paranamer-2.3.jar:/usr/lib/hbase/bin/../lib/protobuf-java-2.5.0.jar:/usr/lib/hbase/bin/../lib/servlet-api-2.5-6.1.14.jar:/usr/lib/hbase/bin/../lib/servlet-api-2.5.jar:/usr/lib/hbase/bin/../lib/slf4j-api-1.6.4.jar:/usr/lib/hbase/bin/../lib/snappy-java-1.0.4.1.jar:/usr/lib/
hbase/bin/../lib/stax-api-1.0.1.jar:/usr/lib/hbase/bin/../lib/xmlenc-0.52.jar:/usr/lib/hbase/bin/../lib/xz-1.0.jar:/usr/lib/hbase/bin/../lib/zookeeper.jar:/etc/hadoop/conf:/usr/lib/hadoop/lib/jetty-6.1.26.jar:/usr/lib/hadoop/lib/jetty-util-6.1.26.jar:/usr/lib/hadoop/lib/jasper-compiler-5.5.23.jar:/usr/lib/hadoop/lib/slf4j-log4j12-1.7.5.jar:/usr/lib/hadoop/lib/paranamer-2.3.jar:/usr/lib/hadoop/lib/commons-beanutils-1.7.0.jar:/usr/lib/hadoop/lib/jersey-core-1.9.jar:/usr/lib/hadoop/lib/commons-lang-2.5.jar:/usr/lib/hadoop/lib/commons-codec-1.4.jar:/usr/lib/hadoop/lib/hadoop-tools.jar:/usr/lib/hadoop/lib/asm-3.2.jar:/usr/lib/hadoop/lib/jettison-1.1.jar:/usr/lib/hadoop/lib/commons-collections-3.2.1.jar:/usr/lib/hadoop/lib/jsch-0.1.42.jar:/usr/lib/hadoop/lib/commons-el-1.0.jar:/usr/lib/hadoop/lib/commons-logging-1.1.1.jar:/usr/lib/hadoop/lib/xmlenc-0.52.jar:/usr/lib/hadoop/lib/commons-configuration-1.6.jar:/usr/lib/hadoop/lib/commons-httpclient-3.1.jar:/usr/lib/hadoop/lib/protobuf-java-2.
5.0.jar:/usr/lib/hadoop/lib/activation-1.1.jar:/usr/lib/hadoop/lib/slf4j-api-1.7.5.jar:/usr/lib/hadoop/lib/jsr305-1.3.9.jar:/usr/lib/hadoop/lib/commons-net-3.1.jar:/usr/lib/hadoop/lib/jasper-runtime-5.5.23.jar:/usr/lib/hadoop/lib/log4j-1.2.17.jar:/usr/lib/hadoop/lib/mockito-all-1.8.5.jar:/usr/lib/hadoop/lib/jaxb-impl-2.2.3-1.jar:/usr/lib/hadoop/lib/zookeeper-3.4.5.jar:/usr/lib/hadoop/lib/commons-digester-1.8.jar:/usr/lib/hadoop/lib/ambari-log4j-1.4.1.207.jar:/usr/lib/hadoop/lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hadoop/lib/commons-cli-1.2.jar:/usr/lib/hadoop/lib/postgresql-9.1-901-1.jdbc4.jar:/usr/lib/hadoop/lib/commons-io-2.1.jar:/usr/lib/hadoop/lib/jackson-core-asl-1.8.8.jar:/usr/lib/hadoop/lib/jackson-jaxrs-1.8.8.jar:/usr/lib/hadoop/lib/snappy-java-1.0.4.1.jar:/usr/lib/hadoop/lib/servlet-api-2.5.jar:/usr/lib/hadoop/lib/jsp-api-2.1.jar:/usr/lib/hadoop/lib/jersey-server-1.9.jar:/usr/lib/hadoop/lib/hadoop-lzo-0.5.0.jar:/usr/lib/hadoop/lib/netty-3.6.2.Final.jar:/usr/lib/hadoop/lib
/commons-compress-1.4.1.jar:/usr/lib/hadoop/lib/stax-api-1.0.1.jar:/usr/lib/hadoop/lib/junit-4.8.2.jar:/usr/lib/hadoop/lib/commons-math-2.1.jar:/usr/lib/hadoop/lib/jersey-json-1.9.jar:/usr/lib/hadoop/lib/avro-1.7.4.jar:/usr/lib/hadoop/lib/jackson-xc-1.8.8.jar:/usr/lib/hadoop/lib/jets3t-0.6.1.jar:/usr/lib/hadoop/lib/guava-11.0.2.jar:/usr/lib/hadoop/lib/commons-beanutils-core-1.8.0.jar:/usr/lib/hadoop/lib/jaxb-api-2.2.2.jar:/usr/lib/hadoop/lib/xz-1.0.jar:/usr/lib/hadoop/.//hadoop-auth-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop/.//hadoop-common-2.2.0.2.0.6.0-76-tests.jar:/usr/lib/hadoop/.//hadoop-nfs-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop/.//hadoop-common-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop/.//hadoop-annotations-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-hdfs/./:/usr/lib/hadoop-hdfs/lib/jetty-6.1.26.jar:/usr/lib/hadoop-hdfs/lib/jetty-util-6.1.26.jar:/usr/lib/hadoop-hdfs/lib/jersey-core-1.9.jar:/usr/lib/hadoop-hdfs/lib/commons-lang-2.5.jar:/usr/lib/hadoop-hdfs/lib/commons-codec-1.4.jar:/usr/lib/hado
op-hdfs/lib/asm-3.2.jar:/usr/lib/hadoop-hdfs/lib/commons-el-1.0.jar:/usr/lib/hadoop-hdfs/lib/commons-logging-1.1.1.jar:/usr/lib/hadoop-hdfs/lib/xmlenc-0.52.jar:/usr/lib/hadoop-hdfs/lib/protobuf-java-2.5.0.jar:/usr/lib/hadoop-hdfs/lib/jsr305-1.3.9.jar:/usr/lib/hadoop-hdfs/lib/jasper-runtime-5.5.23.jar:/usr/lib/hadoop-hdfs/lib/log4j-1.2.17.jar:/usr/lib/hadoop-hdfs/lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hadoop-hdfs/lib/commons-cli-1.2.jar:/usr/lib/hadoop-hdfs/lib/commons-io-2.1.jar:/usr/lib/hadoop-hdfs/lib/jackson-core-asl-1.8.8.jar:/usr/lib/hadoop-hdfs/lib/servlet-api-2.5.jar:/usr/lib/hadoop-hdfs/lib/jsp-api-2.1.jar:/usr/lib/hadoop-hdfs/lib/jersey-server-1.9.jar:/usr/lib/hadoop-hdfs/lib/netty-3.6.2.Final.jar:/usr/lib/hadoop-hdfs/lib/commons-daemon-1.0.13.jar:/usr/lib/hadoop-hdfs/lib/guava-11.0.2.jar:/usr/lib/hadoop-hdfs/.//hadoop-hdfs-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-hdfs/.//hadoop-hdfs-nfs-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-hdfs/.//hadoop-hdfs-2.2.0.2.0.6.0-76-tests.jar:/usr
/lib/hadoop-yarn/lib/jersey-guice-1.9.jar:/usr/lib/hadoop-yarn/lib/paranamer-2.3.jar:/usr/lib/hadoop-yarn/lib/jersey-core-1.9.jar:/usr/lib/hadoop-yarn/lib/javax.inject-1.jar:/usr/lib/hadoop-yarn/lib/asm-3.2.jar:/usr/lib/hadoop-yarn/lib/protobuf-java-2.5.0.jar:/usr/lib/hadoop-yarn/lib/log4j-1.2.17.jar:/usr/lib/hadoop-yarn/lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hadoop-yarn/lib/commons-io-2.1.jar:/usr/lib/hadoop-yarn/lib/jackson-core-asl-1.8.8.jar:/usr/lib/hadoop-yarn/lib/aopalliance-1.0.jar:/usr/lib/hadoop-yarn/lib/snappy-java-1.0.4.1.jar:/usr/lib/hadoop-yarn/lib/jersey-server-1.9.jar:/usr/lib/hadoop-yarn/lib/hamcrest-core-1.1.jar:/usr/lib/hadoop-yarn/lib/guice-servlet-3.0.jar:/usr/lib/hadoop-yarn/lib/netty-3.6.2.Final.jar:/usr/lib/hadoop-yarn/lib/junit-4.10.jar:/usr/lib/hadoop-yarn/lib/commons-compress-1.4.1.jar:/usr/lib/hadoop-yarn/lib/guice-3.0.jar:/usr/lib/hadoop-yarn/lib/avro-1.7.4.jar:/usr/lib/hadoop-yarn/lib/xz-1.0.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-web-proxy-2.2
.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-common-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-nodemanager-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-client-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-tests-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-api-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-common-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-applications-distributedshell-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-site-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-resourcemanager-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-applications-unmanaged-am-launcher-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-mapreduce/.//*::/usr/lib/hadoop-mapreduce/*",
+ "StartTime" : 1383230252186,
+ "VmName" : "Java HotSpot(TM) 64-Bit Server VM",
+ "VmVendor" : "Sun Microsystems Inc.",
+ "VmVersion" : "20.6-b01",
+ "InputArguments" : [ "-Dproc_master", "-XX:OnOutOfMemoryError=kill", "-9", "%p", "-Xmx1000m", "-XX:+UseConcMarkSweepGC", "-XX:ErrorFile=/var/log/hbase/hs_err_pid%p.log", "-verbose:gc", "-XX:+PrintGCDetails", "-XX:+PrintGCDateStamps", "-Xloggc:/var/log/hbase/gc.log-201310311437", "-Xmx1024m", "-Dhbase.log.dir=/var/log/hbase", "-Dhbase.log.file=hbase-hbase-master-c6401.ambari.apache.org.log", "-Dhbase.home.dir=/usr/lib/hbase/bin/..", "-Dhbase.id.str=hbase", "-Dhbase.root.logger=INFO,RFA", "-Djava.library.path=:/usr/lib/hadoop/lib/native/Linux-amd64-64:/usr/lib/hadoop/lib/native", "-Dhbase.security.logger=INFO,RFAS" ],
+ "BootClassPath" : "/usr/jdk64/jdk1.6.0_31/jre/lib/resources.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/rt.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/sunrsasign.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/jsse.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/jce.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/charsets.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/modules/jdk.boot.jar:/usr/jdk64/jdk1.6.0_31/jre/classes",
+ "LibraryPath" : ":/usr/lib/hadoop/lib/native/Linux-amd64-64:/usr/lib/hadoop/lib/native",
+ "BootClassPathSupported" : true,
+ "ManagementSpecVersion" : "1.2",
+ "SpecName" : "Java Virtual Machine Specification",
+ "SpecVendor" : "Sun Microsystems Inc.",
+ "SpecVersion" : "1.0",
+ "SystemProperties" : [ {
+ "key" : "java.ext.dirs",
+ "value" : "/usr/jdk64/jdk1.6.0_31/jre/lib/ext:/usr/java/packages/lib/ext"
+ }, {
+ "key" : "java.vm.specification.vendor",
+ "value" : "Sun Microsystems Inc."
+ }, {
+ "key" : "hbase.log.dir",
+ "value" : "/var/log/hbase"
+ }, {
+ "key" : "user.timezone",
+ "value" : "UTC"
+ }, {
+ "key" : "proc_master",
+ "value" : ""
+ }, {
+ "key" : "java.vm.vendor",
+ "value" : "Sun Microsystems Inc."
+ }, {
+ "key" : "user.name",
+ "value" : "hbase"
+ }, {
+ "key" : "java.vm.specification.name",
+ "value" : "Java Virtual Machine Specification"
+ }, {
+ "key" : "user.dir",
+ "value" : "/home/hbase"
+ }, {
+ "key" : "user.country",
+ "value" : "US"
+ }, {
+ "key" : "user.language",
+ "value" : "en"
+ }, {
+ "key" : "java.specification.version",
+ "value" : "1.6"
+ }, {
+ "key" : "hadoop.policy.file",
+ "value" : "hbase-policy.xml"
+ }, {
+ "key" : "sun.cpu.endian",
+ "value" : "little"
+ }, {
+ "key" : "java.home",
+ "value" : "/usr/jdk64/jdk1.6.0_31/jre"
+ }, {
+ "key" : "hbase.log.file",
+ "value" : "hbase-hbase-master-c6401.ambari.apache.org.log"
+ }, {
+ "key" : "sun.jnu.encoding",
+ "value" : "UTF-8"
+ }, {
+ "key" : "file.separator",
+ "value" : "/"
+ }, {
+ "key" : "java.vendor.url",
+ "value" : "http://java.sun.com/"
+ }, {
+ "key" : "java.awt.graphicsenv",
+ "value" : "sun.awt.X11GraphicsEnvironment"
+ }, {
+ "key" : "os.arch",
+ "value" : "amd64"
+ }, {
+ "key" : "java.io.tmpdir",
+ "value" : "/tmp"
+ }, {
+ "key" : "java.runtime.name",
+ "value" : "Java(TM) SE Runtime Environment"
+ }, {
+ "key" : "java.awt.printerjob",
+ "value" : "sun.print.PSPrinterJob"
+ }, {
+ "key" : "file.encoding",
+ "value" : "UTF-8"
+ }, {
+ "key" : "java.version",
+ "value" : "1.6.0_31"
+ }, {
+ "key" : "java.vendor.url.bug",
+ "value" : "http://java.sun.com/cgi-bin/bugreport.cgi"
+ }, {
+ "key" : "java.vm.specification.version",
+ "value" : "1.0"
+ }, {
+ "key" : "file.encoding.pkg",
+ "value" : "sun.io"
+ }, {
+ "key" : "sun.java.command",
+ "value" : "org.apache.hadoop.hbase.master.HMaster start"
+ }, {
+ "key" : "sun.java.launcher",
+ "value" : "SUN_STANDARD"
+ }, {
+ "key" : "path.separator",
+ "value" : ":"
+ }, {
+ "key" : "java.runtime.version",
+ "value" : "1.6.0_31-b04"
+ }, {
+ "key" : "java.class.path",
+ "value" : "/etc/hbase/conf:/usr/jdk64/jdk1.6.0_31/lib/tools.jar:/usr/lib/hbase/bin/..:/usr/lib/hbase/bin/../lib/activation-1.1.jar:/usr/lib/hbase/bin/../lib/aopalliance-1.0.jar:/usr/lib/hbase/bin/../lib/asm-3.1.jar:/usr/lib/hbase/bin/../lib/avro-1.7.4.jar:/usr/lib/hbase/bin/../lib/commons-beanutils-1.7.0.jar:/usr/lib/hbase/bin/../lib/commons-beanutils-core-1.8.0.jar:/usr/lib/hbase/bin/../lib/commons-cli-1.2.jar:/usr/lib/hbase/bin/../lib/commons-codec-1.7.jar:/usr/lib/hbase/bin/../lib/commons-collections-3.2.1.jar:/usr/lib/hbase/bin/../lib/commons-compress-1.4.1.jar:/usr/lib/hbase/bin/../lib/commons-configuration-1.6.jar:/usr/lib/hbase/bin/../lib/commons-daemon-1.0.13.jar:/usr/lib/hbase/bin/../lib/commons-digester-1.8.jar:/usr/lib/hbase/bin/../lib/commons-el-1.0.jar:/usr/lib/hbase/bin/../lib/commons-httpclient-3.1.jar:/usr/lib/hbase/bin/../lib/commons-io-2.4.jar:/usr/lib/hbase/bin/../lib/commons-lang-2.6.jar:/usr/lib/hbase/bin/../lib/commons-logging-1.1.1.jar:/usr/lib/hbase/bin
/../lib/commons-math-2.2.jar:/usr/lib/hbase/bin/../lib/commons-net-3.1.jar:/usr/lib/hbase/bin/../lib/core-3.1.1.jar:/usr/lib/hbase/bin/../lib/findbugs-annotations-1.3.9-1.jar:/usr/lib/hbase/bin/../lib/gmbal-api-only-3.0.0-b023.jar:/usr/lib/hbase/bin/../lib/grizzly-framework-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-http-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-http-server-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-http-servlet-2.1.2.jar:/usr/lib/hbase/bin/../lib/grizzly-rcm-2.1.2.jar:/usr/lib/hbase/bin/../lib/guava-12.0.1.jar:/usr/lib/hbase/bin/../lib/guice-3.0.jar:/usr/lib/hbase/bin/../lib/guice-servlet-3.0.jar:/usr/lib/hbase/bin/../lib/hbase-client-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-common-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-common-0.96.0.2.0.6.0-76-hadoop2-tests.jar:/usr/lib/hbase/bin/../lib/hbase-examples-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-hadoop2-compat-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/h
base/bin/../lib/hbase-hadoop-compat-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-it-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-it-0.96.0.2.0.6.0-76-hadoop2-tests.jar:/usr/lib/hbase/bin/../lib/hbase-prefix-tree-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-protocol-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-server-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-server-0.96.0.2.0.6.0-76-hadoop2-tests.jar:/usr/lib/hbase/bin/../lib/hbase-shell-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-testing-util-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/hbase-thrift-0.96.0.2.0.6.0-76-hadoop2.jar:/usr/lib/hbase/bin/../lib/high-scale-lib-1.1.1.jar:/usr/lib/hbase/bin/../lib/htrace-core-2.01.jar:/usr/lib/hbase/bin/../lib/httpclient-4.1.3.jar:/usr/lib/hbase/bin/../lib/httpcore-4.1.3.jar:/usr/lib/hbase/bin/../lib/jackson-core-asl-1.8.8.jar:/usr/lib/hbase/bin/../lib/jackson-jaxrs-1.8.8.jar:/
usr/lib/hbase/bin/../lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hbase/bin/../lib/jackson-xc-1.8.8.jar:/usr/lib/hbase/bin/../lib/jamon-runtime-2.3.1.jar:/usr/lib/hbase/bin/../lib/jasper-compiler-5.5.23.jar:/usr/lib/hbase/bin/../lib/jasper-runtime-5.5.23.jar:/usr/lib/hbase/bin/../lib/javax.inject-1.jar:/usr/lib/hbase/bin/../lib/javax.servlet-3.1.jar:/usr/lib/hbase/bin/../lib/javax.servlet-api-3.0.1.jar:/usr/lib/hbase/bin/../lib/jaxb-api-2.2.2.jar:/usr/lib/hbase/bin/../lib/jaxb-impl-2.2.3-1.jar:/usr/lib/hbase/bin/../lib/jersey-client-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-core-1.8.jar:/usr/lib/hbase/bin/../lib/jersey-grizzly2-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-guice-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-json-1.8.jar:/usr/lib/hbase/bin/../lib/jersey-server-1.8.jar:/usr/lib/hbase/bin/../lib/jersey-test-framework-core-1.9.jar:/usr/lib/hbase/bin/../lib/jersey-test-framework-grizzly2-1.9.jar:/usr/lib/hbase/bin/../lib/jets3t-0.6.1.jar:/usr/lib/hbase/bin/../lib/jettison-1.3.1.jar:/u
sr/lib/hbase/bin/../lib/jetty-6.1.26.jar:/usr/lib/hbase/bin/../lib/jetty-sslengine-6.1.26.jar:/usr/lib/hbase/bin/../lib/jetty-util-6.1.26.jar:/usr/lib/hbase/bin/../lib/jruby-complete-1.6.8.jar:/usr/lib/hbase/bin/../lib/jsch-0.1.42.jar:/usr/lib/hbase/bin/../lib/jsp-2.1-6.1.14.jar:/usr/lib/hbase/bin/../lib/jsp-api-2.1-6.1.14.jar:/usr/lib/hbase/bin/../lib/jsp-api-2.1.jar:/usr/lib/hbase/bin/../lib/jsr305-1.3.9.jar:/usr/lib/hbase/bin/../lib/junit-4.11.jar:/usr/lib/hbase/bin/../lib/libthrift-0.9.0.jar:/usr/lib/hbase/bin/../lib/log4j-1.2.17.jar:/usr/lib/hbase/bin/../lib/management-api-3.0.0-b012.jar:/usr/lib/hbase/bin/../lib/metrics-core-2.1.2.jar:/usr/lib/hbase/bin/../lib/netty-3.6.6.Final.jar:/usr/lib/hbase/bin/../lib/paranamer-2.3.jar:/usr/lib/hbase/bin/../lib/protobuf-java-2.5.0.jar:/usr/lib/hbase/bin/../lib/servlet-api-2.5-6.1.14.jar:/usr/lib/hbase/bin/../lib/servlet-api-2.5.jar:/usr/lib/hbase/bin/../lib/slf4j-api-1.6.4.jar:/usr/lib/hbase/bin/../lib/snappy-java-1.0.4.1.jar:/usr/lib/hb
ase/bin/../lib/stax-api-1.0.1.jar:/usr/lib/hbase/bin/../lib/xmlenc-0.52.jar:/usr/lib/hbase/bin/../lib/xz-1.0.jar:/usr/lib/hbase/bin/../lib/zookeeper.jar:/etc/hadoop/conf:/usr/lib/hadoop/lib/jetty-6.1.26.jar:/usr/lib/hadoop/lib/jetty-util-6.1.26.jar:/usr/lib/hadoop/lib/jasper-compiler-5.5.23.jar:/usr/lib/hadoop/lib/slf4j-log4j12-1.7.5.jar:/usr/lib/hadoop/lib/paranamer-2.3.jar:/usr/lib/hadoop/lib/commons-beanutils-1.7.0.jar:/usr/lib/hadoop/lib/jersey-core-1.9.jar:/usr/lib/hadoop/lib/commons-lang-2.5.jar:/usr/lib/hadoop/lib/commons-codec-1.4.jar:/usr/lib/hadoop/lib/hadoop-tools.jar:/usr/lib/hadoop/lib/asm-3.2.jar:/usr/lib/hadoop/lib/jettison-1.1.jar:/usr/lib/hadoop/lib/commons-collections-3.2.1.jar:/usr/lib/hadoop/lib/jsch-0.1.42.jar:/usr/lib/hadoop/lib/commons-el-1.0.jar:/usr/lib/hadoop/lib/commons-logging-1.1.1.jar:/usr/lib/hadoop/lib/xmlenc-0.52.jar:/usr/lib/hadoop/lib/commons-configuration-1.6.jar:/usr/lib/hadoop/lib/commons-httpclient-3.1.jar:/usr/lib/hadoop/lib/protobuf-java-2.5.
0.jar:/usr/lib/hadoop/lib/activation-1.1.jar:/usr/lib/hadoop/lib/slf4j-api-1.7.5.jar:/usr/lib/hadoop/lib/jsr305-1.3.9.jar:/usr/lib/hadoop/lib/commons-net-3.1.jar:/usr/lib/hadoop/lib/jasper-runtime-5.5.23.jar:/usr/lib/hadoop/lib/log4j-1.2.17.jar:/usr/lib/hadoop/lib/mockito-all-1.8.5.jar:/usr/lib/hadoop/lib/jaxb-impl-2.2.3-1.jar:/usr/lib/hadoop/lib/zookeeper-3.4.5.jar:/usr/lib/hadoop/lib/commons-digester-1.8.jar:/usr/lib/hadoop/lib/ambari-log4j-1.4.1.207.jar:/usr/lib/hadoop/lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hadoop/lib/commons-cli-1.2.jar:/usr/lib/hadoop/lib/postgresql-9.1-901-1.jdbc4.jar:/usr/lib/hadoop/lib/commons-io-2.1.jar:/usr/lib/hadoop/lib/jackson-core-asl-1.8.8.jar:/usr/lib/hadoop/lib/jackson-jaxrs-1.8.8.jar:/usr/lib/hadoop/lib/snappy-java-1.0.4.1.jar:/usr/lib/hadoop/lib/servlet-api-2.5.jar:/usr/lib/hadoop/lib/jsp-api-2.1.jar:/usr/lib/hadoop/lib/jersey-server-1.9.jar:/usr/lib/hadoop/lib/hadoop-lzo-0.5.0.jar:/usr/lib/hadoop/lib/netty-3.6.2.Final.jar:/usr/lib/hadoop/lib/c
ommons-compress-1.4.1.jar:/usr/lib/hadoop/lib/stax-api-1.0.1.jar:/usr/lib/hadoop/lib/junit-4.8.2.jar:/usr/lib/hadoop/lib/commons-math-2.1.jar:/usr/lib/hadoop/lib/jersey-json-1.9.jar:/usr/lib/hadoop/lib/avro-1.7.4.jar:/usr/lib/hadoop/lib/jackson-xc-1.8.8.jar:/usr/lib/hadoop/lib/jets3t-0.6.1.jar:/usr/lib/hadoop/lib/guava-11.0.2.jar:/usr/lib/hadoop/lib/commons-beanutils-core-1.8.0.jar:/usr/lib/hadoop/lib/jaxb-api-2.2.2.jar:/usr/lib/hadoop/lib/xz-1.0.jar:/usr/lib/hadoop/.//hadoop-auth-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop/.//hadoop-common-2.2.0.2.0.6.0-76-tests.jar:/usr/lib/hadoop/.//hadoop-nfs-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop/.//hadoop-common-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop/.//hadoop-annotations-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-hdfs/./:/usr/lib/hadoop-hdfs/lib/jetty-6.1.26.jar:/usr/lib/hadoop-hdfs/lib/jetty-util-6.1.26.jar:/usr/lib/hadoop-hdfs/lib/jersey-core-1.9.jar:/usr/lib/hadoop-hdfs/lib/commons-lang-2.5.jar:/usr/lib/hadoop-hdfs/lib/commons-codec-1.4.jar:/usr/lib/hadoop
-hdfs/lib/asm-3.2.jar:/usr/lib/hadoop-hdfs/lib/commons-el-1.0.jar:/usr/lib/hadoop-hdfs/lib/commons-logging-1.1.1.jar:/usr/lib/hadoop-hdfs/lib/xmlenc-0.52.jar:/usr/lib/hadoop-hdfs/lib/protobuf-java-2.5.0.jar:/usr/lib/hadoop-hdfs/lib/jsr305-1.3.9.jar:/usr/lib/hadoop-hdfs/lib/jasper-runtime-5.5.23.jar:/usr/lib/hadoop-hdfs/lib/log4j-1.2.17.jar:/usr/lib/hadoop-hdfs/lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hadoop-hdfs/lib/commons-cli-1.2.jar:/usr/lib/hadoop-hdfs/lib/commons-io-2.1.jar:/usr/lib/hadoop-hdfs/lib/jackson-core-asl-1.8.8.jar:/usr/lib/hadoop-hdfs/lib/servlet-api-2.5.jar:/usr/lib/hadoop-hdfs/lib/jsp-api-2.1.jar:/usr/lib/hadoop-hdfs/lib/jersey-server-1.9.jar:/usr/lib/hadoop-hdfs/lib/netty-3.6.2.Final.jar:/usr/lib/hadoop-hdfs/lib/commons-daemon-1.0.13.jar:/usr/lib/hadoop-hdfs/lib/guava-11.0.2.jar:/usr/lib/hadoop-hdfs/.//hadoop-hdfs-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-hdfs/.//hadoop-hdfs-nfs-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-hdfs/.//hadoop-hdfs-2.2.0.2.0.6.0-76-tests.jar:/usr/l
ib/hadoop-yarn/lib/jersey-guice-1.9.jar:/usr/lib/hadoop-yarn/lib/paranamer-2.3.jar:/usr/lib/hadoop-yarn/lib/jersey-core-1.9.jar:/usr/lib/hadoop-yarn/lib/javax.inject-1.jar:/usr/lib/hadoop-yarn/lib/asm-3.2.jar:/usr/lib/hadoop-yarn/lib/protobuf-java-2.5.0.jar:/usr/lib/hadoop-yarn/lib/log4j-1.2.17.jar:/usr/lib/hadoop-yarn/lib/jackson-mapper-asl-1.8.8.jar:/usr/lib/hadoop-yarn/lib/commons-io-2.1.jar:/usr/lib/hadoop-yarn/lib/jackson-core-asl-1.8.8.jar:/usr/lib/hadoop-yarn/lib/aopalliance-1.0.jar:/usr/lib/hadoop-yarn/lib/snappy-java-1.0.4.1.jar:/usr/lib/hadoop-yarn/lib/jersey-server-1.9.jar:/usr/lib/hadoop-yarn/lib/hamcrest-core-1.1.jar:/usr/lib/hadoop-yarn/lib/guice-servlet-3.0.jar:/usr/lib/hadoop-yarn/lib/netty-3.6.2.Final.jar:/usr/lib/hadoop-yarn/lib/junit-4.10.jar:/usr/lib/hadoop-yarn/lib/commons-compress-1.4.1.jar:/usr/lib/hadoop-yarn/lib/guice-3.0.jar:/usr/lib/hadoop-yarn/lib/avro-1.7.4.jar:/usr/lib/hadoop-yarn/lib/xz-1.0.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-web-proxy-2.2.0
.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-common-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-nodemanager-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-client-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-tests-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-api-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-common-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-applications-distributedshell-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-site-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-server-resourcemanager-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-yarn/.//hadoop-yarn-applications-unmanaged-am-launcher-2.2.0.2.0.6.0-76.jar:/usr/lib/hadoop-mapreduce/.//*::/usr/lib/hadoop-mapreduce/*"
+ }, {
+ "key" : "os.name",
+ "value" : "Linux"
+ }, {
+ "key" : "hbase.home.dir",
+ "value" : "/usr/lib/hbase/bin/.."
+ }, {
+ "key" : "line.separator",
+ "value" : "\n"
+ }, {
+ "key" : "os.version",
+ "value" : "2.6.32-358.el6.x86_64"
+ }, {
+ "key" : "sun.arch.data.model",
+ "value" : "64"
+ }, {
+ "key" : "java.class.version",
+ "value" : "50.0"
+ }, {
+ "key" : "sun.io.unicode.encoding",
+ "value" : "UnicodeLittle"
+ }, {
+ "key" : "java.vendor",
+ "value" : "Sun Microsystems Inc."
+ }, {
+ "key" : "sun.boot.class.path",
+ "value" : "/usr/jdk64/jdk1.6.0_31/jre/lib/resources.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/rt.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/sunrsasign.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/jsse.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/jce.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/charsets.jar:/usr/jdk64/jdk1.6.0_31/jre/lib/modules/jdk.boot.jar:/usr/jdk64/jdk1.6.0_31/jre/classes"
+ }, {
+ "key" : "hbase.root.logger",
+ "value" : "INFO,RFA"
+ }, {
+ "key" : "java.vm.info",
+ "value" : "mixed mode"
+ }, {
+ "key" : "java.specification.name",
+ "value" : "Java Platform API Specification"
+ }, {
+ "key" : "java.vm.name",
+ "value" : "Java HotSpot(TM) 64-Bit Server VM"
+ }, {
+ "key" : "java.vm.version",
+ "value" : "20.6-b01"
+ }, {
+ "key" : "sun.boot.library.path",
+ "value" : "/usr/jdk64/jdk1.6.0_31/jre/lib/amd64"
+ }, {
+ "key" : "java.endorsed.dirs",
+ "value" : "/usr/jdk64/jdk1.6.0_31/jre/lib/endorsed"
+ }, {
+ "key" : "sun.os.patch.level",
+ "value" : "unknown"
+ }, {
+ "key" : "sun.cpu.isalist",
+ "value" : ""
+ }, {
+ "key" : "hbase.security.logger",
+ "value" : "INFO,RFAS"
+ }, {
+ "key" : "hbase.id.str",
+ "value" : "hbase"
+ }, {
+ "key" : "user.home",
+ "value" : "/home/hbase"
+ }, {
+ "key" : "java.library.path",
+ "value" : ":/usr/lib/hadoop/lib/native/Linux-amd64-64:/usr/lib/hadoop/lib/native"
+ }, {
+ "key" : "java.specification.vendor",
+ "value" : "Sun Microsystems Inc."
+ }, {
+ "key" : "sun.management.compiler",
+ "value" : "HotSpot 64-Bit Tiered Compilers"
+ } ],
+ "Uptime" : 3403983
+ }, {
+ "name" : "java.lang:type=ClassLoading",
+ "modelerType" : "sun.management.ClassLoadingImpl",
+ "LoadedClassCount" : 4774,
+ "UnloadedClassCount" : 0,
+ "TotalLoadedClassCount" : 4774,
+ "Verbose" : false
+ }, {
+ "name" : "java.lang:type=Threading",
+ "modelerType" : "sun.management.ThreadImpl",
+ "ThreadAllocatedMemoryEnabled" : true,
+ "ThreadAllocatedMemorySupported" : true,
+ "DaemonThreadCount" : 101,
+ "PeakThreadCount" : 120,
+ "CurrentThreadCpuTimeSupported" : true,
+ "ObjectMonitorUsageSupported" : true,
+ "SynchronizerUsageSupported" : true,
+ "ThreadContentionMonitoringEnabled" : false,
+ "ThreadContentionMonitoringSupported" : true,
+ "ThreadCpuTimeEnabled" : true,
+ "AllThreadIds" : [ 339, 323, 271, 146, 145, 144, 143, 109, 110, 105, 108, 107, 106, 104, 103, 101, 100, 97, 96, 12, 93, 92, 91, 90, 89, 88, 87, 86, 85, 84, 83, 82, 81, 80, 79, 78, 77, 76, 75, 74, 73, 72, 71, 70, 69, 68, 67, 66, 65, 64, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41, 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 13, 26, 29, 28, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14, 5, 3, 2, 1 ],
+ "CurrentThreadCpuTime" : 40000000,
+ "CurrentThreadUserTime" : 40000000,
+ "ThreadCount" : 104,
+ "TotalStartedThreadCount" : 331,
+ "ThreadCpuTimeSupported" : true
+ }, {
+ "name" : "java.util.logging:type=Logging",
+ "modelerType" : "java.util.logging.Logging",
+ "LoggerNames" : [ "com.google.common.collect.MapMakerInternalMap", "sun.awt.AppContext", "com.google.common.cache.LocalCache", "javax.management", "com.google.common.cache.CacheBuilder", "global", "javax.management.mbeanserver", "" ]
+ }, {
+ "name" : "Hadoop:service=HBase,name=MetricsSystem,sub=Stats",
+ "modelerType" : "MetricsSystem,sub=Stats",
+ "tag.Context" : "metricssystem",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "NumActiveSources" : 8,
+ "NumAllSources" : 8,
+ "NumActiveSinks" : 1,
+ "NumAllSinks" : 0,
+ "Sink_gangliaNumOps" : 339,
+ "Sink_gangliaAvgTime" : 3.0,
+ "Sink_gangliaDropped" : 0,
+ "Sink_gangliaQsize" : 0,
+ "SnapshotNumOps" : 3059,
+ "SnapshotAvgTime" : 0.11111111111111113,
+ "PublishNumOps" : 339,
+ "PublishAvgTime" : 0.0,
+ "DroppedPubAll" : 0
+ }, {
+ "name" : "java.lang:type=MemoryPool,name=Eden Space",
+ "modelerType" : "sun.management.MemoryPoolImpl",
+ "Name" : "Eden Space",
+ "Type" : "HEAP",
+ "Valid" : true,
+ "Usage" : {
+ "committed" : 17432576,
+ "init" : 17432576,
+ "max" : 17432576,
+ "used" : 17101800
+ },
+ "CollectionUsage" : {
+ "committed" : 17432576,
+ "init" : 17432576,
+ "max" : 17432576,
+ "used" : 0
+ },
+ "CollectionUsageThreshold" : 0,
+ "CollectionUsageThresholdCount" : 0,
+ "MemoryManagerNames" : [ "ConcurrentMarkSweep", "Copy" ],
+ "PeakUsage" : {
+ "committed" : 17432576,
+ "init" : 17432576,
+ "max" : 17432576,
+ "used" : 17432576
+ },
+ "CollectionUsageThresholdExceeded" : true,
+ "CollectionUsageThresholdSupported" : true,
+ "UsageThresholdSupported" : false
+ }, {
+ "name" : "com.sun.management:type=HotSpotDiagnostic",
+ "modelerType" : "sun.management.HotSpotDiagnostic",
+ "DiagnosticOptions" : [ {
+ "name" : "HeapDumpBeforeFullGC",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ }, {
+ "name" : "HeapDumpAfterFullGC",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ }, {
+ "name" : "HeapDumpOnOutOfMemoryError",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ }, {
+ "name" : "HeapDumpPath",
+ "origin" : "DEFAULT",
+ "value" : "",
+ "writeable" : true
+ }, {
+ "name" : "CMSAbortablePrecleanWaitMillis",
+ "origin" : "DEFAULT",
+ "value" : "100",
+ "writeable" : true
+ }, {
+ "name" : "CMSWaitDuration",
+ "origin" : "DEFAULT",
+ "value" : "2000",
+ "writeable" : true
+ }, {
+ "name" : "PrintGC",
+ "origin" : "VM_CREATION",
+ "value" : "true",
+ "writeable" : true
+ }, {
+ "name" : "PrintGCDetails",
+ "origin" : "VM_CREATION",
+ "value" : "true",
+ "writeable" : true
+ }, {
+ "name" : "PrintGCDateStamps",
+ "origin" : "VM_CREATION",
+ "value" : "true",
+ "writeable" : true
+ }, {
+ "name" : "PrintGCTimeStamps",
+ "origin" : "VM_CREATION",
+ "value" : "true",
+ "writeable" : true
+ }, {
+ "name" : "PrintClassHistogramBeforeFullGC",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ }, {
+ "name" : "PrintClassHistogramAfterFullGC",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ }, {
+ "name" : "PrintClassHistogram",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ }, {
+ "name" : "PrintConcurrentLocks",
+ "origin" : "DEFAULT",
+ "value" : "false",
+ "writeable" : true
+ } ]
+ }, {
+ "name" : "Hadoop:service=HBase,name=Master,sub=Server",
+ "modelerType" : "Master,sub=Server",
+ "tag.Context" : "master",
+ "tag.zookeeperQuorum" : "c6402.ambari.apache.org:2181,c6401.ambari.apache.org:2181,c6403.ambari.apache.org:2181",
+ "tag.serverName" : "c6401.ambari.apache.org,60000,1383230254260",
+ "tag.clusterId" : "6e7f6a63-5e92-446b-8716-10a231acfc5b",
+ "tag.isActiveMaster" : "true",
+ "tag.Context" : "master",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "masterActiveTime" : 1383230256270,
+ "masterStartTime" : 1383230255394,
+ "averageLoad" : 3.0,
+ "numRegionServers" : 1,
+ "numDeadRegionServers" : 0,
+ "clusterRequests" : 64376
+ }, {
+ "name" : "java.lang:type=MemoryPool,name=Survivor Space",
+ "modelerType" : "sun.management.MemoryPoolImpl",
+ "Name" : "Survivor Space",
+ "Type" : "HEAP",
+ "Valid" : true,
+ "Usage" : {
+ "committed" : 2162688,
+ "init" : 2162688,
+ "max" : 2162688,
+ "used" : 317240
+ },
+ "CollectionUsage" : {
+ "committed" : 2162688,
+ "init" : 2162688,
+ "max" : 2162688,
+ "used" : 317240
+ },
+ "CollectionUsageThreshold" : 0,
+ "CollectionUsageThresholdCount" : 0,
+ "MemoryManagerNames" : [ "ConcurrentMarkSweep", "Copy" ],
+ "PeakUsage" : {
+ "committed" : 2162688,
+ "init" : 2162688,
+ "max" : 2162688,
+ "used" : 1669720
+ },
+ "CollectionUsageThresholdExceeded" : true,
+ "CollectionUsageThresholdSupported" : true,
+ "UsageThresholdSupported" : false
+ }, {
+ "name" : "Hadoop:service=HBase,name=Master,sub=FileSystem",
+ "modelerType" : "Master,sub=FileSystem",
+ "tag.Context" : "master",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "HlogSplitTime_num_ops" : 1,
+ "HlogSplitTime_min" : 72,
+ "HlogSplitTime_max" : 72,
+ "HlogSplitTime_mean" : 72.0,
+ "HlogSplitTime_median" : 72.0,
+ "HlogSplitTime_75th_percentile" : 72.0,
+ "HlogSplitTime_95th_percentile" : 72.0,
+ "HlogSplitTime_99th_percentile" : 72.0,
+ "MetaHlogSplitTime_num_ops" : 1,
+ "MetaHlogSplitTime_min" : 14,
+ "MetaHlogSplitTime_max" : 14,
+ "MetaHlogSplitTime_mean" : 14.0,
+ "MetaHlogSplitTime_median" : 14.0,
+ "MetaHlogSplitTime_75th_percentile" : 14.0,
+ "MetaHlogSplitTime_95th_percentile" : 14.0,
+ "MetaHlogSplitTime_99th_percentile" : 14.0,
+ "MetaHlogSplitSize_num_ops" : 1,
+ "MetaHlogSplitSize_min" : 0,
+ "MetaHlogSplitSize_max" : 0,
+ "MetaHlogSplitSize_mean" : 0.0,
+ "MetaHlogSplitSize_median" : 0.0,
+ "MetaHlogSplitSize_75th_percentile" : 0.0,
+ "MetaHlogSplitSize_95th_percentile" : 0.0,
+ "MetaHlogSplitSize_99th_percentile" : 0.0,
+ "HlogSplitSize_num_ops" : 1,
+ "HlogSplitSize_min" : 0,
+ "HlogSplitSize_max" : 0,
+ "HlogSplitSize_mean" : 0.0,
+ "HlogSplitSize_median" : 0.0,
+ "HlogSplitSize_75th_percentile" : 0.0,
+ "HlogSplitSize_95th_percentile" : 0.0,
+ "HlogSplitSize_99th_percentile" : 0.0
+ }, {
+ "name" : "Hadoop:service=HBase,name=IPC,sub=IPC",
+ "modelerType" : "IPC,sub=IPC",
+ "tag.Context" : "ipc",
+ "tag.Hostname" : "c6401.ambari.apache.org",
+ "QueueCallTime_num_ops" : 1294,
+ "QueueCallTime_min" : 0,
+ "QueueCallTime_max" : 28,
+ "QueueCallTime_mean" : 0.11746522411128284,
+ "QueueCallTime_median" : 0.0,
+ "QueueCallTime_75th_percentile" : 0.0,
+ "QueueCallTime_95th_percentile" : 1.0,
+ "QueueCallTime_99th_percentile" : 1.0,
+ "authenticationFailures" : 0,
+ "authorizationFailures" : 0,
+ "authenticationSuccesses" : 0,
+ "ProcessCallTime_num_ops" : 1294,
+ "ProcessCallTime_min" : 0,
+ "ProcessCallTime_max" : 41,
+ "ProcessCallTime_mean" : 1.2527047913446676,
+ "ProcessCallTime_median" : 0.0,
+ "ProcessCallTime_75th_percentile" : 0.0,
+ "ProcessCallTime_95th_percentile" : 9.0,
+ "ProcessCallTime_99th_percentile" : 25.049999999999955,
+ "sentBytes" : 63071,
+ "receivedBytes" : 375415,
+ "authorizationSuccesses" : 57,
+ "tag.Context.1" : "ipc",
+ "tag.Context.1" : "ipc",
+ "tag.Hostname.1" : "c6401.ambari.apache.org",
+ "queueSize.1" : 0,
+ "numCallsInGeneralQueue.1" : 0,
+ "numCallsInReplicationQueue.1" : 0,
+ "numCallsInPriorityQueue.1" : 0,
+ "numOpenConnections.1" : 1,
+ "QueueCallTime_num_ops.1" : 1294,
+ "QueueCallTime_min.1" : 0,
+ "QueueCallTime_max.1" : 28,
+ "QueueCallTime_mean.1" : 0.11746522411128284,
+ "QueueCallTime_median.1" : 0.0,
+ "QueueCallTime_75th_percentile.1" : 0.0,
+ "QueueCallTime_95th_percentile.1" : 1.0,
+ "QueueCallTime_99th_percentile.1" : 1.0,
+ "authenticationFailures.1" : 0,
+ "authorizationFailures.1" : 0,
+ "authenticationSuccesses.1" : 0,
+ "ProcessCallTime_num_ops.1" : 1294,
+ "ProcessCallTime_min.1" : 0,
+ "ProcessCallTime_max.1" : 41,
+ "ProcessCallTime_mean.1" : 1.2527047913446676,
+ "ProcessCallTime_median.1" : 0.0,
+ "ProcessCallTime_75th_percentile.1" : 0.0,
+ "ProcessCallTime_95th_percentile.1" : 9.0,
+ "ProcessCallTime_99th_percentile.1" : 25.049999999999955,
+ "sentBytes.1" : 63071,
+ "receivedBytes.1" : 375415,
+ "authorizationSuccesses.1" : 57
+ }, {
+ "name" : "JMImplementation:type=MBeanServerDelegate",
+ "modelerType" : "javax.management.MBeanServerDelegate",
+ "MBeanServerId" : "c6401.ambari.apache.org_1383230254134",
+ "SpecificationName" : "Java Management Extensions",
+ "SpecificationVersion" : "1.4",
+ "SpecificationVendor" : "Sun Microsystems",
+ "ImplementationName" : "JMX",
+ "ImplementationVersion" : "1.6.0_31-b04",
+ "ImplementationVendor" : "Sun Microsystems"
+ } ]
+}
\ No newline at end of file
[2/2] git commit: AMBARI-3669. Remove HBase port scanner and
ha_status (ncole)
Posted by nc...@apache.org.
AMBARI-3669. Remove HBase port scanner and ha_status (ncole)
Project: http://git-wip-us.apache.org/repos/asf/incubator-ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ambari/commit/c6c4e348
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ambari/tree/c6c4e348
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ambari/diff/c6c4e348
Branch: refs/heads/trunk
Commit: c6c4e3483d943f1865a5110d91cad9e27f361ba0
Parents: 6b9ca4b
Author: Nate Cole <nc...@hortonworks.com>
Authored: Fri Nov 1 16:33:26 2013 -0400
Committer: Nate Cole <nc...@hortonworks.com>
Committed: Fri Nov 1 17:13:46 2013 -0400
----------------------------------------------------------------------
.../ambari/server/agent/HeartBeatHandler.java | 47 +-
.../ambari/server/agent/HeartbeatMonitor.java | 13 +-
.../server/controller/ControllerModule.java | 51 +-
.../ServiceComponentHostResponse.java | 22 -
.../AbstractControllerResourceProvider.java | 1 -
.../internal/HostComponentResourceProvider.java | 8 -
.../controller/jmx/JMXPropertyProvider.java | 35 +-
.../server/state/ServiceComponentHost.java | 2 -
.../svccomphost/HBaseMasterPortScanner.java | 337 --------
.../svccomphost/ServiceComponentHostImpl.java | 13 -
.../src/main/resources/properties.json | 1 -
.../HostComponentResourceProviderTest.java | 55 --
.../controller/jmx/JMXPropertyProviderTest.java | 39 +-
.../controller/jmx/TestStreamProvider.java | 1 +
.../svccomphost/HBaseMasterPortScannerTest.java | 244 ------
.../test/resources/hbase_hbasemaster_jmx_2.json | 840 +++++++++++++++++++
16 files changed, 960 insertions(+), 749 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java b/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java
index 5b328b5..69a86be 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartBeatHandler.java
@@ -17,16 +17,31 @@
*/
package org.apache.ambari.server.agent;
-import com.google.gson.Gson;
-import com.google.inject.Inject;
-import com.google.inject.Injector;
-import com.google.inject.Singleton;
-import org.apache.ambari.server.*;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+
+import org.apache.ambari.server.AmbariException;
+import org.apache.ambari.server.HostNotFoundException;
+import org.apache.ambari.server.RoleCommand;
+import org.apache.ambari.server.ServiceComponentHostNotFoundException;
+import org.apache.ambari.server.ServiceComponentNotFoundException;
+import org.apache.ambari.server.ServiceNotFoundException;
import org.apache.ambari.server.actionmanager.ActionManager;
import org.apache.ambari.server.api.services.AmbariMetaInfo;
import org.apache.ambari.server.configuration.Configuration;
import org.apache.ambari.server.metadata.ActionMetadata;
-import org.apache.ambari.server.state.*;
+import org.apache.ambari.server.state.AgentVersion;
+import org.apache.ambari.server.state.Cluster;
+import org.apache.ambari.server.state.Clusters;
+import org.apache.ambari.server.state.Host;
+import org.apache.ambari.server.state.HostState;
+import org.apache.ambari.server.state.Service;
+import org.apache.ambari.server.state.ServiceComponent;
+import org.apache.ambari.server.state.ServiceComponentHost;
+import org.apache.ambari.server.state.StackId;
+import org.apache.ambari.server.state.State;
import org.apache.ambari.server.state.fsm.InvalidStateTransitionException;
import org.apache.ambari.server.state.host.HostHealthyHeartbeatEvent;
import org.apache.ambari.server.state.host.HostRegistrationRequestEvent;
@@ -42,12 +57,10 @@ import org.apache.ambari.server.utils.VersionUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.concurrent.ConcurrentHashMap;
-
-import org.apache.ambari.server.state.svccomphost.HBaseMasterPortScanner;
+import com.google.gson.Gson;
+import com.google.inject.Inject;
+import com.google.inject.Injector;
+import com.google.inject.Singleton;
/**
@@ -68,8 +81,6 @@ public class HeartBeatHandler {
AmbariMetaInfo ambariMetaInfo;
@Inject
ActionMetadata actionMetadata;
- @Inject
- HBaseMasterPortScanner scanner;
private HeartbeatMonitor heartbeatMonitor;
@Inject
private Gson gson;
@@ -83,7 +94,6 @@ public class HeartBeatHandler {
this.actionQueue = aq;
this.actionManager = am;
this.heartbeatMonitor = new HeartbeatMonitor(fsm, aq, am, 60000);
- this.heartbeatMonitor.setScanner(scanner);
injector.injectMembers(this);
}
@@ -157,7 +167,6 @@ public class HeartBeatHandler {
hostObject.handleEvent(new HostUnhealthyHeartbeatEvent(hostname, now,
null));
}
- if (hostState != hostObject.getState()) scanner.updateHBaseMaster(hostObject);
} catch (InvalidStateTransitionException ex) {
LOG.warn("Asking agent to reregister due to " + ex.getMessage(), ex);
hostObject.setState(HostState.INIT);
@@ -231,9 +240,6 @@ public class HeartBeatHandler {
scHost.handleEvent(new ServiceComponentHostOpInProgressEvent(schName,
hostname, now));
}
- if (state != scHost.getState() && schName.equals(Role.HBASE_MASTER.toString())) {
- scanner.updateHBaseMaster(cl);
- }
} catch (ServiceComponentNotFoundException scnex) {
LOG.warn("Service component not found ", scnex);
} catch (InvalidStateTransitionException ex) {
@@ -275,9 +281,6 @@ public class HeartBeatHandler {
+ " of cluster " + status.getClusterName()
+ " has changed from " + prevState + " to " + liveState
+ " at host " + hostname);
- if (scHost.getServiceComponentName().equals(Role.HBASE_MASTER.toString())) {
- scanner.updateHBaseMaster(scHost);
- }
}
}
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartbeatMonitor.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartbeatMonitor.java b/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartbeatMonitor.java
index 6161c63..bb348c6 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartbeatMonitor.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/agent/HeartbeatMonitor.java
@@ -18,10 +18,10 @@
package org.apache.ambari.server.agent;
import java.util.ArrayList;
+import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.TreeMap;
-import java.util.HashMap;
import org.apache.ambari.server.AmbariException;
import org.apache.ambari.server.actionmanager.ActionManager;
@@ -37,7 +37,6 @@ import org.apache.ambari.server.state.ServiceComponentHost;
import org.apache.ambari.server.state.State;
import org.apache.ambari.server.state.fsm.InvalidStateTransitionException;
import org.apache.ambari.server.state.host.HostHeartbeatLostEvent;
-import org.apache.ambari.server.state.svccomphost.HBaseMasterPortScanner;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -52,11 +51,6 @@ public class HeartbeatMonitor implements Runnable {
private final int threadWakeupInterval; //1 minute
private volatile boolean shouldRun = true;
private Thread monitorThread = null;
- private HBaseMasterPortScanner scanner;
-
- public void setScanner(HBaseMasterPortScanner scanner) {
- this.scanner = scanner;
- }
public HeartbeatMonitor(Clusters fsm, ActionQueue aq, ActionManager am,
int threadWakeupInterval) {
@@ -141,11 +135,6 @@ public class HeartbeatMonitor implements Runnable {
}
}
- // hbase
- if (hostState != hostObj.getState() && scanner != null) {
- scanner.updateHBaseMaster(hostObj);
- }
-
//Purge action queue
actionQueue.dequeueAll(host);
//notify action manager
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java
index f35e277..1b2ebda 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java
@@ -18,36 +18,52 @@
package org.apache.ambari.server.controller;
-import org.apache.ambari.server.state.configgroup.ConfigGroup;
-import org.apache.ambari.server.state.configgroup.ConfigGroupFactory;
-import org.apache.ambari.server.state.configgroup.ConfigGroupImpl;
-import org.apache.ambari.server.state.svccomphost.HBaseMasterPortScanner;
-import com.google.gson.Gson;
-import com.google.inject.Scopes;
-import com.google.inject.assistedinject.FactoryModuleBuilder;
-import com.google.inject.persist.jpa.JpaPersistModule;
-import org.apache.ambari.server.actionmanager.*;
+import java.util.Map;
+import java.util.Map.Entry;
+import java.util.Properties;
+
+import org.apache.ambari.server.actionmanager.ActionDBAccessor;
+import org.apache.ambari.server.actionmanager.ActionDBAccessorImpl;
+import org.apache.ambari.server.actionmanager.ExecutionCommandWrapper;
+import org.apache.ambari.server.actionmanager.HostRoleCommandFactory;
+import org.apache.ambari.server.actionmanager.HostRoleCommandFactoryImpl;
+import org.apache.ambari.server.actionmanager.StageFactory;
import org.apache.ambari.server.configuration.Configuration;
import org.apache.ambari.server.orm.PersistenceType;
import org.apache.ambari.server.serveraction.ServerActionManager;
import org.apache.ambari.server.serveraction.ServerActionManagerImpl;
-import org.apache.ambari.server.state.*;
+import org.apache.ambari.server.state.Cluster;
+import org.apache.ambari.server.state.Clusters;
+import org.apache.ambari.server.state.Config;
+import org.apache.ambari.server.state.ConfigFactory;
+import org.apache.ambari.server.state.ConfigImpl;
+import org.apache.ambari.server.state.Host;
+import org.apache.ambari.server.state.Service;
+import org.apache.ambari.server.state.ServiceComponent;
+import org.apache.ambari.server.state.ServiceComponentFactory;
+import org.apache.ambari.server.state.ServiceComponentHost;
+import org.apache.ambari.server.state.ServiceComponentHostFactory;
+import org.apache.ambari.server.state.ServiceComponentImpl;
+import org.apache.ambari.server.state.ServiceFactory;
+import org.apache.ambari.server.state.ServiceImpl;
import org.apache.ambari.server.state.cluster.ClusterFactory;
import org.apache.ambari.server.state.cluster.ClusterImpl;
import org.apache.ambari.server.state.cluster.ClustersImpl;
+import org.apache.ambari.server.state.configgroup.ConfigGroup;
+import org.apache.ambari.server.state.configgroup.ConfigGroupFactory;
+import org.apache.ambari.server.state.configgroup.ConfigGroupImpl;
import org.apache.ambari.server.state.host.HostFactory;
import org.apache.ambari.server.state.host.HostImpl;
-
-import com.google.inject.AbstractModule;
-import com.google.inject.Singleton;
-import com.google.inject.name.Names;
import org.apache.ambari.server.state.svccomphost.ServiceComponentHostImpl;
import org.springframework.security.crypto.password.PasswordEncoder;
import org.springframework.security.crypto.password.StandardPasswordEncoder;
-import java.util.Map;
-import java.util.Map.Entry;
-import java.util.Properties;
+import com.google.gson.Gson;
+import com.google.inject.AbstractModule;
+import com.google.inject.Scopes;
+import com.google.inject.assistedinject.FactoryModuleBuilder;
+import com.google.inject.name.Names;
+import com.google.inject.persist.jpa.JpaPersistModule;
/**
* Used for injection purposes.
@@ -91,7 +107,6 @@ public class ControllerModule extends AbstractModule {
bind(AmbariManagementController.class)
.to(AmbariManagementControllerImpl.class);
bind(AbstractRootServiceResponseFactory.class).to(RootServiceResponseFactory.class);
- bind(HBaseMasterPortScanner.class).in(Singleton.class);
bind(ServerActionManager.class).to(ServerActionManagerImpl.class);
requestStaticInjection(ExecutionCommandWrapper.class);
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentHostResponse.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentHostResponse.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentHostResponse.java
index eba7da8..e773871 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentHostResponse.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentHostResponse.java
@@ -48,8 +48,6 @@ public class ServiceComponentHostResponse {
private String desiredState;
- private String ha_status = "NA";
-
private boolean staleConfig = false;
@@ -198,26 +196,6 @@ public class ServiceComponentHostResponse {
this.clusterName = clusterName;
}
- /**
- *
- * @return ha_status status of HBaseMaster
- */
- public String getHa_status() {
- return ha_status;
- }
-
-
- /**
- *
- * @param ha_status the state of HBaseMaster
- */
- public void setHa_status(String ha_status) {
- this.ha_status = ha_status;
- }
-
-
-
-
@Override
public boolean equals(Object o) {
if (this == o) return true;
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java
index 464040e..dc2575e 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java
@@ -20,7 +20,6 @@ package org.apache.ambari.server.controller.internal;
import org.apache.ambari.server.controller.AmbariManagementController;
import org.apache.ambari.server.controller.predicate.ArrayPredicate;
-import org.apache.ambari.server.controller.predicate.ComparisonPredicate;
import org.apache.ambari.server.controller.predicate.EqualsPredicate;
import org.apache.ambari.server.controller.spi.Predicate;
import org.apache.ambari.server.controller.spi.Resource;
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java
index 006e59b..eb419f3 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java
@@ -58,8 +58,6 @@ class HostComponentResourceProvider extends AbstractControllerResourceProvider {
= PropertyHelper.getPropertyId("HostRoles", "configs");
protected static final String HOST_COMPONENT_DESIRED_CONFIGS_PROPERTY_ID
= PropertyHelper.getPropertyId("HostRoles", "desired_configs");
- protected static final String HOST_COMPONENT_HIGH_AVAILABILITY_PROPERTY_ID
- = PropertyHelper.getPropertyId("HostRoles", "ha_status");
protected static final String HOST_COMPONENT_STACK_ID_PROPERTY_ID
= PropertyHelper.getPropertyId("HostRoles", "stack_id");
protected static final String HOST_COMPONENT_DESIRED_STACK_ID_PROPERTY_ID
@@ -166,11 +164,6 @@ class HostComponentResourceProvider extends AbstractControllerResourceProvider {
for (ServiceComponentHostResponse response : responses) {
Resource resource = new ResourceImpl(Resource.Type.HostComponent);
- if((response.getComponentName()).equals(Role.HBASE_MASTER.toString())) {
- requestedIds.add(HOST_COMPONENT_HIGH_AVAILABILITY_PROPERTY_ID);
- }else{
- requestedIds.remove(HOST_COMPONENT_HIGH_AVAILABILITY_PROPERTY_ID);
- }
setResourceProperty(resource, HOST_COMPONENT_CLUSTER_NAME_PROPERTY_ID, response.getClusterName(), requestedIds);
setResourceProperty(resource, HOST_COMPONENT_SERVICE_NAME_PROPERTY_ID, response.getServiceName(), requestedIds);
setResourceProperty(resource, HOST_COMPONENT_COMPONENT_NAME_PROPERTY_ID, response.getComponentName(), requestedIds);
@@ -181,7 +174,6 @@ class HostComponentResourceProvider extends AbstractControllerResourceProvider {
response.getStackVersion(), requestedIds);
setResourceProperty(resource, HOST_COMPONENT_DESIRED_STACK_ID_PROPERTY_ID,
response.getDesiredStackVersion(), requestedIds);
- setResourceProperty(resource, HOST_COMPONENT_HIGH_AVAILABILITY_PROPERTY_ID, response.getHa_status(), requestedIds);
setResourceProperty(resource, HOST_COMPONENT_CONFIGS_PROPERTY_ID,
response.getConfigs(), requestedIds);
setResourceProperty(resource, HOST_COMPONENT_DESIRED_CONFIGS_PROPERTY_ID,
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/controller/jmx/JMXPropertyProvider.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/jmx/JMXPropertyProvider.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/jmx/JMXPropertyProvider.java
index baa39bd..1f9bbff 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/jmx/JMXPropertyProvider.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/jmx/JMXPropertyProvider.java
@@ -344,24 +344,33 @@ public class JMXPropertyProvider extends AbstractPropertyProvider {
String property = propertyInfo.getPropertyId();
String category = "";
+
List<String> keyList = new LinkedList<String>();
- int keyStartIndex = property.indexOf('[', 0);
- int firstKeyIndex = keyStartIndex > -1 ? keyStartIndex : property.length();
- while (keyStartIndex > -1) {
+
+ int keyStartIndex = property.indexOf('[');
+ if (-1 != keyStartIndex) {
int keyEndIndex = property.indexOf(']', keyStartIndex);
- if (keyEndIndex > -1 & keyEndIndex > keyStartIndex) {
- keyList.add(property.substring(keyStartIndex + 1, keyEndIndex));
- keyStartIndex = property.indexOf('[', keyEndIndex);
- }
- else {
- keyStartIndex = -1;
+ if (-1 != keyEndIndex && keyEndIndex > keyStartIndex) {
+ keyList.add(property.substring(keyStartIndex+1, keyEndIndex));
}
}
+
+ if (!containsArguments(propertyId)) {
+ int dotIndex = property.indexOf('.', property.indexOf('='));
+ if (-1 != dotIndex) {
+ category = property.substring(0, dotIndex);
+ property = (-1 == keyStartIndex) ?
+ property.substring(dotIndex+1) :
+ property.substring(dotIndex+1, keyStartIndex);
+ }
+ } else {
+ int firstKeyIndex = keyStartIndex > -1 ? keyStartIndex : property.length();
+ int dotIndex = property.lastIndexOf('.', firstKeyIndex);
- int dotIndex = property.lastIndexOf('.', firstKeyIndex - 1);
- if (dotIndex != -1){
- category = property.substring(0, dotIndex);
- property = property.substring(dotIndex + 1, firstKeyIndex);
+ if (dotIndex != -1) {
+ category = property.substring(0, dotIndex);
+ property = property.substring(dotIndex + 1, firstKeyIndex);
+ }
}
if (containsArguments(propertyId)) {
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/state/ServiceComponentHost.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/state/ServiceComponentHost.java b/ambari-server/src/main/java/org/apache/ambari/server/state/ServiceComponentHost.java
index eb4acf9..627d24d 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/state/ServiceComponentHost.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/state/ServiceComponentHost.java
@@ -86,8 +86,6 @@ public interface ServiceComponentHost {
public void setState(State state);
- public void setHAState(String status);
-
public Map<String, Config> getConfigs() throws AmbariException;
public StackId getStackVersion();
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScanner.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScanner.java b/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScanner.java
deleted file mode 100644
index cdcd800..0000000
--- a/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScanner.java
+++ /dev/null
@@ -1,337 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with this
- * work for additional information regarding copyright ownership. The ASF
- * licenses this file to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package org.apache.ambari.server.state.svccomphost;
-
-import com.google.inject.Inject;
-import com.google.inject.Singleton;
-import java.net.ConnectException;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.Timer;
-import java.util.TimerTask;
-import org.apache.ambari.server.AmbariException;
-import org.apache.ambari.server.Role;
-import org.apache.ambari.server.state.Cluster;
-import org.apache.ambari.server.state.Clusters;
-import org.apache.ambari.server.state.Host;
-import org.apache.ambari.server.state.ServiceComponentHost;
-import org.apache.ambari.server.state.State;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-/**
- * This class encapsulates the HBaseMaster scanner thread. HBaseMaster scanner
- * start scan if Host, ServiceComponentHost or Cluster change own state.
- */
-@Singleton
-public class HBaseMasterPortScanner implements Runnable {
-
- private static Log LOG = LogFactory.getLog(HBaseMasterPortScanner.class);
- private Thread schedulerThread = null;
- private final Object wakeupSyncObject = new Object();
- private int defaultScanTimeoutMsc = 300;
- private int scanTimeoutMsc = defaultScanTimeoutMsc;
- private int testScanTimeoutMsc;
- private int rescanTimeoutMsc = 60000;
- private final int port = 60010;
- private int maxAttempts = 3;
- private int attempts = 0;
- protected int countAttempts = 0;
- private Map<ServiceComponentHost,Boolean> componentHostMap;
- private Cluster currentCluster;
- private Timer scheduleTimer;
- private RescanSchedulerTask rescanSchedulerTask;
- @Inject
- protected Clusters clusters;
-
- /**
- *
- * @param defaultScanTimeoutMsc set default timeout for port scan
- */
- public void setDefaultScanTimeoutMsc(int defaultScanTimeoutMsc) {
- this.defaultScanTimeoutMsc = defaultScanTimeoutMsc;
- this.scanTimeoutMsc = this.defaultScanTimeoutMsc;
- }
-
-
- /**
- *
- * @param maxAttempts set maximum attempts to scan
- */
- public void setMaxAttempts(int maxAttempts) {
- this.maxAttempts = maxAttempts;
- }
-
- /**
- *
- * @param rescanTimeoutMsc timeout for latter rescan
- */
- public void setRescanTimeoutMsc(int rescanTimeoutMsc) {
- this.rescanTimeoutMsc = rescanTimeoutMsc;
- }
-
- /**
- *
- * @return tested value (need unitests)
- */
- public int getTestScanTimeoutMsc() {
- return testScanTimeoutMsc;
- }
-
-
- /**
- *
- * @return task for latter scan
- */
- public RescanSchedulerTask getRescanSchedulerTask() {
- return rescanSchedulerTask;
- }
-
-
- /**
- * true if scanner should run ASAP. We need this flag to avoid sleep in
- * situations, when we receive updateHBaseMaster request during running a
- * scanner iteration.
- */
- private boolean activeAwakeRequest = false;
-
- public HBaseMasterPortScanner(Timer timer) {
- scheduleTimer = timer;
- }
-
- public HBaseMasterPortScanner() {
- scheduleTimer = new Timer();
- this.start();
- }
-
- private void start() {
- schedulerThread = new Thread(this, this.getClass().getSimpleName());
- schedulerThread.start();
- if (LOG.isDebugEnabled()) {
- LOG.debug("HBaseMasterPortScanner started");
- }
- }
-
-
- /**
- * Should be called from another thread when we want HBase Master scanner to
- * make a run ASAP (for example, to process desired configs of SCHs). The
- * method is guaranteed to return quickly.
- */
- public void updateHBaseMaster(Cluster cluster) {
- synchronized (wakeupSyncObject) {
- collectServiceComponentHostsForCluster(cluster);
- if(componentHostMap!=null && !componentHostMap.isEmpty()){
- LOG.debug("HBaseMasterPortScanner start scanning for cluster " + cluster.getClusterName());
- activeAwakeRequest = true;
- wakeupSyncObject.notify();
- } else LOG.debug("No for scan (with HBaseMaster component)");
- }
- }
-
- public void updateHBaseMaster(Host host) {
- synchronized (wakeupSyncObject) {
- Set<Cluster> clustersSet;
- try {
- clustersSet = clusters.getClustersForHost(host.getHostName());
- } catch (AmbariException ex) {
- return;
- }
- Iterator<Cluster> iter = clustersSet.iterator();
- while (iter.hasNext()) {
- collectServiceComponentHostsForCluster(iter.next());
- }
- if(componentHostMap!=null && !componentHostMap.isEmpty()){
- LOG.debug("HBaseMasterPortScanner start scanning for Host " + host.getHostName());
- activeAwakeRequest = true;
- wakeupSyncObject.notify();
- } else LOG.debug("No for scan (with HBaseMaster component)");
- }
- }
-
- public void updateHBaseMaster(ServiceComponentHost host) {
- synchronized (wakeupSyncObject) {
- try {
- collectServiceComponentHostsForCluster(clusters.getCluster(host.getClusterName()));
- } catch (AmbariException ex) {
- LOG.warn(ex);
- return;
- }
- if(componentHostMap!=null && !componentHostMap.isEmpty()){
- LOG.debug("HBaseMasterPortScanner start scanning for ServiceComponentHost " + host.getServiceComponentName());
- activeAwakeRequest = true;
- wakeupSyncObject.notify();
- } else LOG.debug("No for scan (with HBaseMaster component)");
- }
- }
-
- private void collectServiceComponentHostsForCluster(Cluster cluster) {
- currentCluster = cluster;
- componentHostMap = new HashMap<ServiceComponentHost, Boolean>();
- Map<String, Host> hosts = null;
- try {
- hosts = clusters.getHostsForCluster(currentCluster.getClusterName());
- } catch (AmbariException ex) {
- LOG.warn(ex);
- return;
- }
- for (Map.Entry<String, Host> entry : hosts.entrySet()) {
- if (entry.getValue() != null) {
- List<ServiceComponentHost> componentHosts = currentCluster.getServiceComponentHosts(entry.getValue().getHostName());
- for (ServiceComponentHost componentHost : componentHosts) {
- if (componentHost != null && componentHost.getServiceComponentName() != null && componentHost.getServiceComponentName().equals(Role.HBASE_MASTER.toString())) {
- componentHostMap.put(componentHost, false);
- }
- }
- }
- }
-
- }
-
- @Override
- public void run() {
- while (true) {
- execute();
- if (activeAwakeRequest) {
- activeAwakeRequest = false;
- continue;
- }
- try {
- synchronized (wakeupSyncObject) {
- wakeupSyncObject.wait();
- }
- } catch (InterruptedException ex) {
- activeAwakeRequest = true;
- }
- }
- }
-
- protected void execute() {
- if (rescanSchedulerTask != null) {
- rescanSchedulerTask.cancel();
- scheduleTimer.purge();
- }
- activeAwakeRequest = false;
- if (componentHostMap != null) {
- for (Map.Entry<ServiceComponentHost, Boolean> entry : componentHostMap.entrySet()) {
- entry.setValue(scan(entry.getKey().getHostName()));
- if (activeAwakeRequest) {
- scanTimeoutMsc = defaultScanTimeoutMsc;
- attempts = 0;
- break;
- }
- }
- attempts++;
- countAttempts = attempts;
- LOG.info("Attempt to scan of HBASE_MASTER port : " + attempts);
- if (validateScanResults(componentHostMap)) {
- //If results valid set it to ServiceComponentHost
- setScanResults(componentHostMap);
- scanTimeoutMsc = defaultScanTimeoutMsc;
- attempts = 0;
- } else {
- if (attempts <= maxAttempts) {
- //Increase timeout
- scanTimeoutMsc += defaultScanTimeoutMsc;
- testScanTimeoutMsc = scanTimeoutMsc;
- LOG.info("Increase timeout for scan HBASE_MASTER port to : " + scanTimeoutMsc);
- activeAwakeRequest = true;
- } else {
- LOG.info("No valid data about HBASE_MASTER, ports will rescanned after " + rescanTimeoutMsc / 1000 + " seconds");
- scanTimeoutMsc = defaultScanTimeoutMsc;
- attempts = 0;
- //Create task for latter scan
- rescanSchedulerTask = new RescanSchedulerTask(currentCluster);
- scheduleTimer.schedule(rescanSchedulerTask, rescanTimeoutMsc);
- }
- }
-
- }
-
- }
-
- private void setScanResults(Map<ServiceComponentHost, Boolean> scanResuls){
- for (Map.Entry<ServiceComponentHost, Boolean> entry : scanResuls.entrySet()) {
- entry.getKey().setHAState((entry.getValue()) ? "active" : "passive");
- }
- LOG.info("Set result of HBASE_MASTER scan");
- }
-
- private boolean validateScanResults(Map<ServiceComponentHost, Boolean> scanResuls) {
- boolean res = false;
- int activeMasters = 0;
- int startedComponents = 0;
- for (Map.Entry<ServiceComponentHost, Boolean> entry : scanResuls.entrySet()) {
- activeMasters += (entry.getValue() && entry.getKey().getState() == State.STARTED) ? 1 : 0;
- startedComponents += (entry.getKey().getState() == State.STARTED) ? 1 : 0;
- }
- if (startedComponents > 0) {
- if (activeMasters == 0 || activeMasters > 1) {
- res = false;
- } else {
- res = true;
- }
- } else {
- if (activeMasters > 0) {
- res = false;
- } else {
- res = true;
- }
- }
- LOG.info("Results of HBASE_MASTER scan are " + ((res) ? "valid" : "invalid"));
- return res;
- }
-
- protected boolean scan(String hostname) {
- try {
- Socket socket = new Socket();
- socket.connect(new InetSocketAddress(hostname, port), scanTimeoutMsc);
- socket.close();
- LOG.info(hostname + ":" + port + " HBASE_MASTER active");
- return true;
- } catch (ConnectException e) {
- LOG.info(hostname + ":" + port + " HBASE_MASTER passive");
- return false;
- } catch (Exception ex) {
- LOG.info(hostname + ":" + port + " HBASE_MASTER passive");
- LOG.error(ex);
- return false;
- }
- }
-
- private class RescanSchedulerTask extends TimerTask {
-
- private Cluster cl;
-
- public RescanSchedulerTask(Cluster cl) {
- this.cl = cl;
- }
-
- @Override
- public void run() {
- LOG.info("Start scheduled rescan of HBASE_MASTER ports for cluster "+ cl.getClusterName());
- updateHBaseMaster(cl);
- }
-
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java b/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java
index 2c79f96..71ae98f 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/state/svccomphost/ServiceComponentHostImpl.java
@@ -103,7 +103,6 @@ public class ServiceComponentHostImpl implements ServiceComponentHost {
private long lastOpStartTime;
private long lastOpEndTime;
private long lastOpLastUpdateTime;
- private String ha_status = "passive";
private Map<String, DesiredConfig> actualConfigs = new HashMap<String, DesiredConfig>();
private static final StateMachineFactory
@@ -487,17 +486,6 @@ public class ServiceComponentHostImpl implements ServiceComponentHost {
private final StateMachine<State,
ServiceComponentHostEventType, ServiceComponentHostEvent> stateMachine;
- @Override
- public void setHAState(String status) {
- try {
- writeLock.lock();
- ha_status = status;
- }
- finally {
- writeLock.unlock();
- }
- }
-
static class ServiceComponentHostOpCompletedTransition
implements SingleArcTransition<ServiceComponentHostImpl,
ServiceComponentHostEvent> {
@@ -1315,7 +1303,6 @@ public class ServiceComponentHostImpl implements ServiceComponentHost {
getDesiredState().toString(),
getDesiredStackVersion().getStackId());
- r.setHa_status(ha_status);
r.setActualConfigs(actualConfigs);
try {
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/main/resources/properties.json
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/properties.json b/ambari-server/src/main/resources/properties.json
index fd02437..fa04735 100644
--- a/ambari-server/src/main/resources/properties.json
+++ b/ambari-server/src/main/resources/properties.json
@@ -67,7 +67,6 @@
"HostRoles/actual_configs",
"params/run_smoke_test",
"HostRoles/nagios_alerts",
- "HostRoles/ha_status",
"HostRoles/stale_configs",
"_"
],
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java
index 95c412c..b84f96e 100644
--- a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java
+++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java
@@ -41,7 +41,6 @@ import java.util.LinkedHashMap;
import java.util.LinkedHashSet;
import java.util.Map;
import java.util.Set;
-import org.apache.ambari.server.Role;
import static org.easymock.EasyMock.createMock;
import static org.easymock.EasyMock.createNiceMock;
@@ -176,60 +175,6 @@ public class HostComponentResourceProviderTest {
verify(managementController);
}
-
- @Test
- public void testGetResources_return_ha_status_property() throws Exception {
- Resource.Type type = Resource.Type.HostComponent;
- AmbariManagementController managementController = createMock(AmbariManagementController.class);
- Set<ServiceComponentHostResponse> allResponse = new HashSet<ServiceComponentHostResponse>();
- for (Role role : Role.values()) {
- allResponse.add(new ServiceComponentHostResponse(
- "Cluster100", "Service100", role.toString(), "Host100", null, null, "", "", "", ""));
- }
-
-
-
- // set expectations
- expect(managementController.getHostComponents(
- AbstractResourceProviderTest.Matcher.getHostComponentRequestSet(
- "Cluster100", null, null, null, null, null))).andReturn(allResponse).once();
-
- // replay
- replay(managementController);
-
- ResourceProvider provider = AbstractControllerResourceProvider.getResourceProvider(
- type,
- PropertyHelper.getPropertyIds(type),
- PropertyHelper.getKeyPropertyIds(type),
- managementController);
-
- Set<String> propertyIds = new HashSet<String>();
-
- propertyIds.add(HostComponentResourceProvider.HOST_COMPONENT_CLUSTER_NAME_PROPERTY_ID);
- propertyIds.add(HostComponentResourceProvider.HOST_COMPONENT_COMPONENT_NAME_PROPERTY_ID);
-
- Predicate predicate = new PredicateBuilder().property(
- HostComponentResourceProvider.HOST_COMPONENT_CLUSTER_NAME_PROPERTY_ID).equals("Cluster100").toPredicate();
- Request request = PropertyHelper.getReadRequest(propertyIds);
- Set<Resource> resources = provider.getResources(request, predicate);
-
- for (Resource resource : resources) {
- Object ha_status = resource.getPropertyValue(
- HostComponentResourceProvider.HOST_COMPONENT_HIGH_AVAILABILITY_PROPERTY_ID);
- //ha_status must have only HBASE_MASTER component
- if(ha_status != null)
- {
- Assert.assertEquals(Role.HBASE_MASTER.toString(), resource.getPropertyValue(
- HostComponentResourceProvider.HOST_COMPONENT_COMPONENT_NAME_PROPERTY_ID).toString());
- }else{
- Assert.assertNotSame(Role.HBASE_MASTER.toString(), resource.getPropertyValue(
- HostComponentResourceProvider.HOST_COMPONENT_COMPONENT_NAME_PROPERTY_ID).toString());
- }
- }
-
- verify(managementController);
- }
-
@Test
public void testUpdateResources() throws Exception {
Resource.Type type = Resource.Type.HostComponent;
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/JMXPropertyProviderTest.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/JMXPropertyProviderTest.java b/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/JMXPropertyProviderTest.java
index 38684ab..bd417df 100644
--- a/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/JMXPropertyProviderTest.java
+++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/JMXPropertyProviderTest.java
@@ -808,6 +808,42 @@ public class JMXPropertyProviderTest {
Assert.assertEquals(preSize, resource.getPropertiesMap().size());
}
+
+ @Test
+ public void testPopulateResources_HBaseMaster2() throws Exception {
+ TestStreamProvider streamProvider = new TestStreamProvider();
+ TestJMXHostProvider hostProvider = new TestJMXHostProvider(false);
+
+ JMXPropertyProvider propertyProvider = new JMXPropertyProvider(
+ PropertyHelper.getJMXPropertyIds(Resource.Type.HostComponent, PropertyHelper.MetricsVersion.HDP2),
+ streamProvider,
+ hostProvider,
+ PropertyHelper.getPropertyId("HostRoles", "cluster_name"),
+ PropertyHelper.getPropertyId("HostRoles", "host_name"),
+ PropertyHelper.getPropertyId("HostRoles", "component_name"),
+ PropertyHelper.getPropertyId("HostRoles", "state"),
+ Collections.singleton("STARTED"));
+
+ Resource resource = new ResourceImpl(Resource.Type.HostComponent);
+
+ resource.setProperty("HostRoles/cluster_name", "HBM2");
+ resource.setProperty(HOST_COMPONENT_HOST_NAME_PROPERTY_ID, "domu-12-31-39-0e-34-e1.compute-1.internal");
+ resource.setProperty(HOST_COMPONENT_COMPONENT_NAME_PROPERTY_ID, "HBASE_MASTER");
+ resource.setProperty(HOST_COMPONENT_STATE_PROPERTY_ID, "STARTED");
+
+
+ // request with an empty set should get all supported properties
+ Request request = PropertyHelper.getReadRequest(Collections.<String>emptySet());
+
+ Set<Resource> res = propertyProvider.populateResources(Collections.singleton(resource), request, null);
+ Assert.assertEquals(1, res.size());
+
+ Map<String, Map<String, Object>> map = res.iterator().next().getPropertiesMap();
+
+ Assert.assertTrue(map.containsKey("metrics/hbase/master"));
+ // uses 'tag.isActiveMaster' (name with a dot)
+ Assert.assertTrue(map.get("metrics/hbase/master").containsKey("IsActiveMaster"));
+ }
private static class TestJMXHostProvider implements JMXHostProvider {
private final boolean unknownPort;
@@ -828,6 +864,7 @@ public class JMXPropertyProviderTest {
if (unknownPort) {
return null;
}
+
if (componentName.equals("NAMENODE"))
return "50070";
else if (componentName.equals("DATANODE"))
@@ -837,7 +874,7 @@ public class JMXPropertyProviderTest {
else if (componentName.equals("TASKTRACKER"))
return "50060";
else if (componentName.equals("HBASE_MASTER"))
- return "60010";
+ return null == clusterName ? "60010" : "60011";
else if (componentName.equals("JOURNALNODE"))
return "8480";
else
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/TestStreamProvider.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/TestStreamProvider.java b/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/TestStreamProvider.java
index 4f0a6d3..8d7832e 100644
--- a/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/TestStreamProvider.java
+++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/jmx/TestStreamProvider.java
@@ -35,6 +35,7 @@ public class TestStreamProvider implements StreamProvider {
FILE_MAPPING.put("50030", "mapreduce_jobtracker_jmx.json");
FILE_MAPPING.put("50060", "mapreduce_tasktracker_jmx.json");
FILE_MAPPING.put("60010", "hbase_hbasemaster_jmx.json");
+ FILE_MAPPING.put("60011", "hbase_hbasemaster_jmx_2.json");
FILE_MAPPING.put("8088", "resourcemanager_jmx.json");
FILE_MAPPING.put("8480", "hdfs_journalnode_jmx.json");
}
http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/c6c4e348/ambari-server/src/test/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScannerTest.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScannerTest.java b/ambari-server/src/test/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScannerTest.java
deleted file mode 100644
index a88b037..0000000
--- a/ambari-server/src/test/java/org/apache/ambari/server/state/svccomphost/HBaseMasterPortScannerTest.java
+++ /dev/null
@@ -1,244 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with this
- * work for additional information regarding copyright ownership. The ASF
- * licenses this file to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package org.apache.ambari.server.state.svccomphost;
-
-
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
-import com.google.inject.Guice;
-import com.google.inject.Injector;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import java.util.Timer;
-import org.apache.ambari.server.AmbariException;
-import static org.apache.ambari.server.agent.DummyHeartbeatConstants.DATANODE;
-import static org.apache.ambari.server.agent.DummyHeartbeatConstants.DummyCluster;
-import static org.apache.ambari.server.agent.DummyHeartbeatConstants.DummyOsType;
-import static org.apache.ambari.server.agent.DummyHeartbeatConstants.HDFS;
-import static org.apache.ambari.server.agent.DummyHeartbeatConstants.HBASE_MASTER;
-import static org.apache.ambari.server.agent.DummyHeartbeatConstants.NAMENODE;
-import org.apache.ambari.server.api.services.AmbariMetaInfo;
-import org.apache.ambari.server.orm.GuiceJpaInitializer;
-import org.apache.ambari.server.orm.InMemoryDefaultTestModule;
-import org.apache.ambari.server.state.Cluster;
-import org.apache.ambari.server.state.Clusters;
-import org.apache.ambari.server.state.Host;
-import org.apache.ambari.server.state.Service;
-import org.apache.ambari.server.state.ServiceComponentHost;
-import org.apache.ambari.server.state.ServiceFactory;
-import org.apache.ambari.server.state.StackId;
-import org.apache.ambari.server.state.State;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.Test;
-import static org.junit.Assert.*;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- *
- * @author root
- */
-public class HBaseMasterPortScannerTest {
-
- private static final Logger log = LoggerFactory.getLogger(HBaseMasterPortScannerTest.class);
- private static List<String> hostnames;
- private static Injector injector;
- private static HBaseMasterPortScannerMock scaner;
- private static ServiceFactory serviceFactory;
- private static AmbariMetaInfo metaInfo;
- private static Clusters clusters;
- private static Cluster cluster;
- private static Host host;
- private static ServiceComponentHost serviceComponentHost;
- private static int scanTimeOut = 100;
- private static int reScanTimeOut = 1000;
- private static int maxAttempts = 2;
- private static Timer timerMock = mock(Timer.class);
-
- public HBaseMasterPortScannerTest() {
- }
-
- @BeforeClass
- public static void setUpClass() throws Exception {
- injector = Guice.createInjector(new InMemoryDefaultTestModule());
- injector.getInstance(GuiceJpaInitializer.class);
- hostnames = new ArrayList<String>();
- hostnames.add("127.0.0.1");
- hostnames.add("host1");
- hostnames.add("host2");
- hostnames.add("host3");
- clusters = injector.getInstance(Clusters.class);
- scaner = new HBaseMasterPortScannerMock(clusters);
- metaInfo = injector.getInstance(AmbariMetaInfo.class);
- serviceFactory = injector.getInstance(ServiceFactory.class);
- metaInfo.init();
- clusters.addCluster(DummyCluster);
- cluster = clusters.getCluster(DummyCluster);
- cluster.setDesiredStackVersion(new StackId("HDP-0.2"));
- Set<String> hostNamesSet = new HashSet<String>();
- for (String hostname : hostnames) {
- clusters.addHost(hostname);
- clusters.getHost(hostname).persist();
- Host hostObject = clusters.getHost(hostname);
- hostObject.setIPv4("ipv4");
- hostObject.setIPv6("ipv6");
- hostObject.setOsType(DummyOsType);
- hostNamesSet.add(hostname);
- if (hostname.equals("127.0.0.1")) {
- host = hostObject;
- }
- }
- clusters.mapHostsToCluster(hostNamesSet, DummyCluster);
- Service service = cluster.addService(HDFS);
- service.persist();
- service.addServiceComponent(NAMENODE).persist();
- service.getServiceComponent(NAMENODE).addServiceComponentHost("127.0.0.1").persist();
- service.addServiceComponent(DATANODE).persist();
- service.getServiceComponent(DATANODE).addServiceComponentHost("127.0.0.1").persist();
- service = serviceFactory.createNew(cluster, "HBASE");
- cluster.addService(service);
- service.persist();
- service = cluster.getService("HBASE");
- service.addServiceComponent(HBASE_MASTER).persist();
- service.persist();
- for (String hostname : hostnames) {
- service.getServiceComponent(HBASE_MASTER).addServiceComponentHost(hostname).persist();
- if (hostname.equals("127.0.0.1")) {
- serviceComponentHost = service.getServiceComponent(HBASE_MASTER).getServiceComponentHost(hostname);
- serviceComponentHost.setState(State.STARTED);
- }
- }
- when(timerMock.purge()).thenReturn(0);
- }
-
-
- @Before
- public void setUp() throws AmbariException, Exception {
- serviceComponentHost.setHAState("passive");
- }
-
- /**
- * Test of updateHBaseMaster method, of class HBaseMasterPortScaner.
- */
- @Test
- public void testUpdateHBaseMaster_Cluster() throws InterruptedException {
- scaner.setDefaultScanTimeoutMsc(scanTimeOut);
- scaner.setMaxAttempts(maxAttempts);
- scaner.setRescanTimeoutMsc(reScanTimeOut);
- log.debug("updateHBaseMaster - pass Cluster");
- scaner.updateHBaseMaster(cluster);
- scaner.execute();
- assertEquals("active", serviceComponentHost.convertToResponse().getHa_status());
- }
-
- /**
- * Test of updateHBaseMaster method, of class HBaseMasterPortScaner.
- */
- @Test
- public void testUpdateHBaseMaster_Host() throws InterruptedException {
- scaner.setDefaultScanTimeoutMsc(scanTimeOut);
- scaner.setMaxAttempts(maxAttempts);
- scaner.setRescanTimeoutMsc(reScanTimeOut);
- log.debug("updateHBaseMaster - pass Host");
- scaner.updateHBaseMaster(host);
- scaner.execute();
- assertEquals("active", serviceComponentHost.convertToResponse().getHa_status());
- }
-
- /**
- * Test of updateHBaseMaster method, of class HBaseMasterPortScaner.
- */
- @Test
- public void testUpdateHBaseMaster_ServiceComponentHost() throws InterruptedException {
- scaner.setDefaultScanTimeoutMsc(scanTimeOut);
- scaner.setMaxAttempts(maxAttempts);
- scaner.setRescanTimeoutMsc(reScanTimeOut);
- log.debug("updateHBaseMaster - pass ServiceComponentHost");
- scaner.updateHBaseMaster(serviceComponentHost);
- scaner.execute();
- assertEquals("active", serviceComponentHost.convertToResponse().getHa_status());
- }
-
-
- /**
- * Test case of if port is closed or not enough scan timeout.
- */
- @Test
- public void testOfBrokenMasterScenario() throws InterruptedException {
- scaner.setLiveHBaseHost("");
- scaner.setDefaultScanTimeoutMsc(scanTimeOut);
- scaner.setMaxAttempts(maxAttempts);
- scaner.setRescanTimeoutMsc(reScanTimeOut);
- log.debug("testOfBrokenMasterScenario start");
- scaner.updateHBaseMaster(cluster);
- scaner.execute(3);
- //Should not be active masters
- assertEquals("passive", serviceComponentHost.convertToResponse().getHa_status());
- serviceComponentHost.setHAState("passive");
- //Scanner should try to scan maxAttempts times
- assertEquals(maxAttempts, scaner.getCountAttempts()-1);
- //Timeout for scan should be scanTimeOut * scaner.getCountAttempts()
- assertEquals(scanTimeOut * scaner.getCountAttempts(), scaner.getTestScanTimeoutMsc());
- //Task for latter scan shoul be created
- assertNotNull(scaner.getRescanSchedulerTask());
- scaner.setLiveHBaseHost("127.0.0.1");
- scaner.execute(3);
- //Test active masters after latter rescan
- assertEquals("active", serviceComponentHost.convertToResponse().getHa_status());
- }
-
-
- public static class HBaseMasterPortScannerMock extends HBaseMasterPortScanner {
-
- private String liveHBaseHost = "127.0.0.1";
-
- public void setLiveHBaseHost(String liveHBaseHost) {
- this.liveHBaseHost = liveHBaseHost;
- }
-
- @Override
- protected boolean scan(String hostname) {
- return (hostname.equals(liveHBaseHost)) ? true : false;
- }
-
- public int getCountAttempts() {
- return countAttempts;
- }
-
-
- public HBaseMasterPortScannerMock(Clusters c) {
- super(timerMock);
- clusters = c;
- }
-
- @Override
- public void execute() {
- super.execute();
- }
-
- public void execute(int count) {
- for (int i = 0; i < count; i++) {
- execute();
- }
- }
-
- }
-
-}
\ No newline at end of file