diff options
author | Yusaku Sako <yusaku@apache.org> | 2012-12-09 13:40:13 +0000 |
---|---|---|
committer | Yusaku Sako <yusaku@apache.org> | 2012-12-09 13:40:13 +0000 |
commit | 9628208297029988e2d04f8e2597ba8f3013393e (patch) | |
tree | 50d5d17c2c79e77646be554d5b1add0a69ec38eb /ambari-web | |
parent | 8bf497655267cf5120e7a5989aae7be2111c4d4a (diff) |
AMBARI-1015. Create HBase summary section in Dashboard & Service pages. (Srimanth Gunturi via yusaku)
git-svn-id: https://svn.apache.org/repos/asf/incubator/ambari/branches/AMBARI-666@1418949 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'ambari-web')
-rw-r--r-- | ambari-web/app/assets/data/dashboard/serviceComponents.json | 44 | ||||
-rw-r--r-- | ambari-web/app/assets/data/dashboard/services.json | 978 | ||||
-rw-r--r-- | ambari-web/app/controllers/global/cluster_controller.js | 27 | ||||
-rw-r--r-- | ambari-web/app/controllers/main/dashboard.js | 16 | ||||
-rw-r--r-- | ambari-web/app/mappers/services_mapper.js | 50 | ||||
-rw-r--r-- | ambari-web/app/messages.js | 13 | ||||
-rw-r--r-- | ambari-web/app/models.js | 1 | ||||
-rw-r--r-- | ambari-web/app/models/service/hbase.js | 33 | ||||
-rw-r--r-- | ambari-web/app/routes/main.js | 4 | ||||
-rw-r--r-- | ambari-web/app/styles/application.less | 2 | ||||
-rw-r--r-- | ambari-web/app/templates/main/dashboard/service/hbase.hbs | 73 | ||||
-rw-r--r-- | ambari-web/app/templates/main/service/info/summary.hbs | 40 | ||||
-rw-r--r-- | ambari-web/app/views/main/dashboard.js | 1 | ||||
-rw-r--r-- | ambari-web/app/views/main/dashboard/service/hbase.js | 103 | ||||
-rw-r--r-- | ambari-web/app/views/main/dashboard/service/mapreduce.js | 2 | ||||
-rw-r--r-- | ambari-web/app/views/main/service/info/summary.js | 20 |
16 files changed, 1246 insertions, 161 deletions
diff --git a/ambari-web/app/assets/data/dashboard/serviceComponents.json b/ambari-web/app/assets/data/dashboard/serviceComponents.json index da9743d7ff..49828f18a3 100644 --- a/ambari-web/app/assets/data/dashboard/serviceComponents.json +++ b/ambari-web/app/assets/data/dashboard/serviceComponents.json @@ -154,6 +154,50 @@ } } ] + }, + { + "href" : "http://ambari/clusters/vmc/services/HBASE", + "ServiceInfo" : { + "cluster_name" : "vmc", + "service_name" : "HBASE" + }, + "components" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_MASTER", + "ServiceComponentInfo" : { + "MasterStartTime" : 1350859237269, + "cluster_name" : "vmc", + "RegionsInTransition" : "[]", + "MasterActiveTime" : 1350859237344, + "component_name" : "HBASE_MASTER", + "state" : "STARTED", + "HeapMemoryUsed" : 9864776, + "Revision" : "Unknown", + "service_name" : "HBASE", + "HeapMemoryMax" : 1807613952, + "Version" : "0.92.1.14", + "AverageLoad" : 1.0 + } + }, + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_CLIENT", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_CLIENT", + "state" : "INSTALLED", + "service_name" : "HBASE" + } + }, + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_REGIONSERVER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_REGIONSERVER", + "state" : "STARTED", + "service_name" : "HBASE" + } + } + ] } ] }
\ No newline at end of file diff --git a/ambari-web/app/assets/data/dashboard/services.json b/ambari-web/app/assets/data/dashboard/services.json index 211c84da75..0ce88886e8 100644 --- a/ambari-web/app/assets/data/dashboard/services.json +++ b/ambari-web/app/assets/data/dashboard/services.json @@ -897,6 +897,984 @@ ] } ] + }, + { + "href" : "http://ambari/clusters/vmc/services/HBASE", + "ServiceInfo" : { + "cluster_name" : "vmc", + "service_name" : "HBASE" + }, + "components" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_CLIENT", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_CLIENT", + "service_name" : "HBASE" + }, + "host_components" : [ + { + "href" : "http://ambari/clusters/vmc/hosts/ip-10-72-35-220.ec2.internal/host_components/HBASE_CLIENT", + "HostRoles" : { + "cluster_name" : "vmc", + "role_id" : "45", + "state" : "INSTALLED", + "component_name" : "HBASE_CLIENT", + "host_name" : "ip-10-72-35-220.ec2.internal" + }, + "metrics" : { + "boottime" : 1.35085738E9, + "process" : { + "proc_total" : 256.0, + "proc_run" : 0.0 + }, + "rpc" : { + "rpcAuthorizationSuccesses" : 0.0, + "SentBytes" : 0.0, + "rpcAuthorizationFailures" : 0.0, + "ReceivedBytes" : 0.0, + "NumOpenConnections" : 0.0, + "callQueueLen" : 0.0, + "rpcAuthenticationSuccesses" : 0.0, + "RpcQueueTime_num_ops" : 0.0, + "RpcProcessingTime_num_ops" : 0.0, + "RpcProcessingTime_avg_time" : 0.833333333, + "rpcAuthenticationFailures" : 0.0, + "RpcQueueTime_avg_time" : 0.0 + }, + "ugi" : { + "loginSuccess_num_ops" : 0.0, + "loginFailure_num_ops" : 0.0, + "loginSuccess_avg_time" : 0.0, + "loginFailure_avg_time" : 0.0 + }, + "disk" : { + "disk_total" : 0.0, + "disk_free" : 845.273, + "part_max_used" : 0.0 + }, + "cpu" : { + "cpu_speed" : 2266.0, + "cpu_num" : 2.0, + "cpu_wio" : 0.0, + "cpu_idle" : 0.0, + "cpu_nice" : 0.0, + "cpu_aidle" : 0.0, + "cpu_system" : 0.0, + "cpu_user" : 0.0 + }, + "jvm" : { + "memHeapCommittedM" : 0.0, + "logFatal" : 0.0, + "threadsBlocked" : 0.0, + "threadsWaiting" : 0.0, + "gcCount" : 4.00522301E7, + "logError" : 0.0, + "logWarn" : 0.0, + "memNonHeapCommittedM" : 0.0, + "gcTimeMillis" : 4.00522105E7, + "memNonHeapUsedM" : 0.0, + "logInfo" : 0.0, + "threadsNew" : 0.0, + "memHeapUsedM" : 25.1243319, + "threadsTerminated" : 0.0, + "threadsTimedWaiting" : 7.86944444, + "maxMemoryM" : 0.0, + "threadsRunnable" : 12.0861111 + }, + "load" : { + "load_fifteen" : 0.0, + "load_one" : 0.0, + "load_five" : 0.0 + }, + "memory" : { + "mem_total" : 0.0, + "swap_free" : 0.0, + "mem_buffers" : 274835.867, + "mem_shared" : 0.0, + "mem_cached" : 0.0, + "mem_free" : 4953373.72, + "swap_total" : 0.0 + }, + "network" : { + "pkts_out" : 85.1731944, + "bytes_in" : 0.0, + "bytes_out" : 16002.9854, + "pkts_in" : 2.26458333 + } + }, + "component" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_CLIENT", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_CLIENT", + "service_name" : "HBASE" + } + } + ] + } + ] + }, + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_MASTER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_MASTER", + "service_name" : "HBASE" + }, + "host_components" : [ + { + "href" : "http://ambari/clusters/vmc/hosts/dev.hortonworks.com/host_components/HBASE_MASTER", + "HostRoles" : { + "cluster_name" : "vmc", + "role_id" : "7", + "state" : "STARTED", + "component_name" : "HBASE_MASTER", + "host_name" : "dev.hortonworks.com" + }, + "metrics" : { + "boottime" : 1.35085737E9, + "process" : { + "proc_total" : 351.569444, + "proc_run" : 0.688888889 + }, + "hbase" : { + "master" : { + "splitSize_avg_time" : 0.0, + "splitTime_avg_time" : 0.0, + "cluster_requests" : 0.0138888892, + "splitTime_num_ops" : 0.0, + "splitSize_num_ops" : 0.0 + } + }, + "disk" : { + "disk_total" : 893.764, + "disk_free" : 844.711, + "part_max_used" : 58.6 + }, + "cpu" : { + "cpu_speed" : 2659.0, + "cpu_num" : 2.0, + "cpu_wio" : 0.0730555556, + "cpu_idle" : 99.8522222, + "cpu_nice" : 0.0, + "cpu_aidle" : 0.0, + "cpu_system" : 0.0247222222, + "cpu_user" : 0.0747222222 + }, + "jvm" : { + "memHeapCommittedM" : 81.0625, + "logFatal" : 0.0, + "threadsBlocked" : 0.0, + "threadsWaiting" : 41.0, + "gcCount" : 15276.8639, + "logError" : 0.0, + "logWarn" : 0.0, + "memNonHeapCommittedM" : 40.242188, + "gcTimeMillis" : 24517.1361, + "memNonHeapUsedM" : 27.285767, + "logInfo" : 0.0, + "threadsNew" : 0.0, + "memHeapUsedM" : 12.2370905, + "threadsTerminated" : 0.0, + "threadsTimedWaiting" : 12.1666667, + "maxMemoryM" : 1723.875, + "threadsRunnable" : 17.0 + }, + "load" : { + "load_fifteen" : 0.0, + "load_one" : 0.035, + "load_five" : 0.0196388889 + }, + "memory" : { + "mem_total" : 7864320.0, + "swap_free" : 0.0, + "mem_buffers" : 227652.0, + "mem_shared" : 0.0, + "mem_cached" : 1911099.56, + "mem_free" : 4251389.64, + "swap_total" : 0.0 + }, + "network" : { + "pkts_out" : 58.7640278, + "bytes_in" : 1492.3225, + "bytes_out" : 11377.1212, + "pkts_in" : 10.5369167 + } + }, + "component" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_MASTER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_MASTER", + "service_name" : "HBASE" + } + } + ] + } + ] + }, + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_REGIONSERVER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_REGIONSERVER", + "service_name" : "HBASE" + }, + "host_components" : [ + { + "href" : "http://ambari/clusters/vmc/hosts/domu-12-31-39-15-6d-4a.compute-1.internal/host_components/HBASE_REGIONSERVER", + "HostRoles" : { + "cluster_name" : "vmc", + "role_id" : "36", + "state" : "STARTED", + "component_name" : "HBASE_REGIONSERVER", + "host_name" : "domu-12-31-39-15-6d-4a.compute-1.internal" + }, + "metrics" : { + "boottime" : 0.0, + "process" : { + "proc_total" : 0.0, + "proc_run" : 0.0 + }, + "rpc" : { + "rpcAuthorizationSuccesses" : 0.0, + "SentBytes" : 0.0, + "rpcAuthorizationFailures" : 0.0, + "ReceivedBytes" : 0.0, + "NumOpenConnections" : 0.0, + "callQueueLen" : 0.0, + "rpcAuthenticationSuccesses" : 0.0, + "RpcQueueTime_num_ops" : 0.0, + "RpcProcessingTime_num_ops" : 0.0, + "RpcProcessingTime_avg_time" : 0.333333333, + "rpcAuthenticationFailures" : 0.0, + "RpcQueueTime_avg_time" : 37.6666667 + }, + "ugi" : { + "loginSuccess_num_ops" : 0.0, + "loginFailure_num_ops" : 0.0, + "loginSuccess_avg_time" : 0.0, + "loginFailure_avg_time" : 0.0 + }, + "hbase" : { + "regionserver" : { + "compactionSize_avg_time" : 0.0, + "deleteRequestLatency_min" : 0.0, + "getRequestLatency_95th_percentile" : 0.0, + "getRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_median" : 0.0, + "getRequestLatency_num_ops" : 0.0, + "hlogFileCount" : 1.0, + "requests" : 0.0, + "fsReadLatencyHistogram_num_ops" : 0.0, + "hdfsBlocksLocalityIndex" : 0.0, + "fsWriteLatencyHistogram_std_dev" : 0.0, + "writeRequestsCount" : 0.0, + "flushSize_avg_time" : 0.0, + "fsWriteLatencyHistogram_max" : 0.0, + "deleteRequestLatency_max" : 0.0, + "deleteRequestLatency_std_dev" : 0.0, + "getRequestLatency_75th_percentile" : 0.0, + "fsSyncLatency_num_ops" : 1996062.63, + "putRequestLatency_max" : 0.0, + "getRequestLatency_mean" : 0.0, + "fsWriteLatencyHistogram_95th_percentile" : 0.0, + "fsSyncLatency_avg_time" : 0.0, + "deleteRequestLatency_num_ops" : 0.0, + "deleteRequestLatency_median" : 0.0, + "compactionTime_num_ops" : 0.0, + "compactionSize_num_ops" : 0.0, + "deleteRequestLatency_mean" : 0.0, + "putRequestLatency_num_ops" : 0.0, + "blockCacheEvictedCount" : 0.0, + "fsReadLatencyHistogram_mean" : 0.0, + "storefileIndexSizeMB" : 0.0, + "fsWriteLatencyHistogram_75th_percentile" : 0.0, + "fsWriteLatency_avg_time" : 0.0, + "fsReadLatencyHistogram_max" : 0.0, + "compactionQueueSize" : 0.0, + "fsWriteLatencyHistogram_min" : 0.0, + "getRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_mean" : 0.0, + "totalStaticBloomSizeKB" : 0.0, + "deleteRequestLatency_99th_percentile" : 0.0, + "putRequestLatency_75th_percentile" : 0.0, + "totalStaticIndexSizeKB" : 0.0, + "putRequestLatency_mean" : 0.0, + "blockCacheFree" : 5.85715584E8, + "fsReadLatency_avg_time" : 0.0, + "deleteRequestLatency_95th_percentile" : 0.0, + "fsWriteLatency_num_ops" : 0.0, + "memstoreSizeMB" : 0.0, + "blockCacheCount" : 0.0, + "regions" : 0.0, + "blockCacheHitRatio" : 0.0, + "flushQueueSize" : 0.0, + "fsReadLatencyHistogram_95th_percentile" : 0.0, + "blockCacheHitCount" : 0.0, + "blockCacheHitCachingRatio" : 0.0, + "flushTime_avg_time" : 0.0, + "putRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_min" : 0.0, + "flushTime_num_ops" : 0.0, + "putRequestLatency_median" : 0.0, + "compactionTime_avg_time" : 0.0, + "getRequestLatency_median" : 0.0, + "fsReadLatency_num_ops" : 0.0, + "readRequestsCount" : 0.0, + "blockCacheSize" : 4845696.0, + "rootIndexSizeKB" : 0.0, + "fsReadLatencyHistogram_std_dev" : 0.0, + "fsReadLatencyHistogram_75th_percentile" : 0.0, + "putRequestLatency_std_dev" : 0.0, + "getRequestLatency_max" : 0.0, + "getRequestLatency_std_dev" : 0.0, + "putRequestLatency_95th_percentile" : 0.0, + "blockCacheMissCount" : 0.0, + "deleteRequestLatency_75th_percentile" : 0.0, + "storefiles" : 1.0, + "fsWriteLatencyHistogram_num_ops" : 0.0, + "flushSize_num_ops" : 0.0, + "putRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_99th_percentile" : 0.0, + "stores" : 0.0, + "fsReadLatencyHistogram_median" : 0.0 + } + }, + "disk" : { + "disk_total" : 0.0, + "disk_free" : 845.541, + "part_max_used" : 0.0 + }, + "cpu" : { + "cpu_speed" : 0.0, + "cpu_num" : 2.0, + "cpu_wio" : 0.0508333333, + "cpu_idle" : 0.0, + "cpu_nice" : 0.0, + "cpu_aidle" : 0.0, + "cpu_system" : 0.0, + "cpu_user" : 0.0 + }, + "jvm" : { + "memHeapCommittedM" : 0.0, + "logFatal" : 0.0, + "threadsBlocked" : 0.0, + "threadsWaiting" : 0.0, + "gcCount" : 0.0, + "logError" : 0.0, + "logWarn" : 0.0, + "memNonHeapCommittedM" : 39.6960069, + "gcTimeMillis" : 8.3513253E7, + "memNonHeapUsedM" : 21.8612905, + "logInfo" : 0.0, + "threadsNew" : 0.0, + "memHeapUsedM" : 54.834693, + "threadsTerminated" : 0.0, + "threadsTimedWaiting" : 0.0, + "maxMemoryM" : 2252.8125, + "threadsRunnable" : 15.6027778 + }, + "load" : { + "load_fifteen" : 0.0, + "load_one" : 0.0, + "load_five" : 0.0 + }, + "memory" : { + "mem_total" : 7864320.0, + "swap_free" : 0.0, + "mem_buffers" : 0.0, + "mem_shared" : 0.0, + "mem_cached" : 0.0, + "mem_free" : 5216872.38, + "swap_total" : 0.0 + }, + "network" : { + "pkts_out" : 0.0, + "bytes_in" : 473.845167, + "bytes_out" : 17525.4473, + "pkts_in" : 0.0 + } + }, + "component" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_REGIONSERVER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_REGIONSERVER", + "service_name" : "HBASE" + } + } + ] + }, + { + "href" : "http://ambari/clusters/vmc/hosts/domu-12-31-39-0b-0c-21.compute-1.internal/host_components/HBASE_REGIONSERVER", + "HostRoles" : { + "cluster_name" : "vmc", + "role_id" : "37", + "state" : "STARTED", + "component_name" : "HBASE_REGIONSERVER", + "host_name" : "domu-12-31-39-0b-0c-21.compute-1.internal" + }, + "metrics" : { + "boottime" : 1.35085738E9, + "process" : { + "proc_total" : 746.186111, + "proc_run" : 2.74166667 + }, + "rpc" : { + "rpcAuthorizationSuccesses" : 0.0, + "SentBytes" : 0.0, + "rpcAuthorizationFailures" : 0.0, + "ReceivedBytes" : 0.0, + "NumOpenConnections" : 0.0, + "callQueueLen" : 0.0, + "rpcAuthenticationSuccesses" : 0.0, + "RpcQueueTime_num_ops" : 0.0, + "RpcProcessingTime_num_ops" : 0.0, + "RpcProcessingTime_avg_time" : 0.0, + "rpcAuthenticationFailures" : 0.0, + "RpcQueueTime_avg_time" : 0.0 + }, + "ugi" : { + "loginSuccess_num_ops" : 0.0, + "loginFailure_num_ops" : 0.0, + "loginSuccess_avg_time" : 0.0, + "loginFailure_avg_time" : 0.0 + }, + "hbase" : { + "regionserver" : { + "compactionSize_avg_time" : 0.0, + "deleteRequestLatency_min" : 0.0, + "getRequestLatency_95th_percentile" : 0.0, + "getRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_median" : 0.0, + "getRequestLatency_num_ops" : 0.0, + "hlogFileCount" : 2.0, + "requests" : 0.0416666667, + "fsReadLatencyHistogram_num_ops" : 0.0, + "hdfsBlocksLocalityIndex" : 0.0, + "fsWriteLatencyHistogram_std_dev" : 0.0, + "writeRequestsCount" : 3.0, + "flushSize_avg_time" : 0.0, + "fsWriteLatencyHistogram_max" : 0.0, + "deleteRequestLatency_max" : 0.0, + "deleteRequestLatency_std_dev" : 0.0, + "getRequestLatency_75th_percentile" : 0.0, + "fsSyncLatency_num_ops" : 0.0, + "putRequestLatency_max" : 0.0, + "getRequestLatency_mean" : 0.0, + "fsWriteLatencyHistogram_95th_percentile" : 0.0, + "fsSyncLatency_avg_time" : 0.0, + "deleteRequestLatency_num_ops" : 0.0, + "deleteRequestLatency_median" : 0.0, + "compactionTime_num_ops" : 0.0, + "compactionSize_num_ops" : 0.0, + "deleteRequestLatency_mean" : 0.0, + "putRequestLatency_num_ops" : 0.0, + "blockCacheEvictedCount" : 0.0, + "fsReadLatencyHistogram_mean" : 0.0, + "storefileIndexSizeMB" : 0.0, + "fsWriteLatencyHistogram_75th_percentile" : 0.0, + "fsWriteLatency_avg_time" : 0.0, + "fsReadLatencyHistogram_max" : 0.0, + "compactionQueueSize" : 0.0, + "fsWriteLatencyHistogram_min" : 0.0, + "getRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_mean" : 0.0, + "totalStaticBloomSizeKB" : 0.0, + "deleteRequestLatency_99th_percentile" : 0.0, + "putRequestLatency_75th_percentile" : 0.0, + "totalStaticIndexSizeKB" : 0.0, + "putRequestLatency_mean" : 0.0, + "blockCacheFree" : 0.0, + "fsReadLatency_avg_time" : 0.0, + "deleteRequestLatency_95th_percentile" : 0.0, + "fsWriteLatency_num_ops" : 3.0, + "memstoreSizeMB" : 0.0, + "blockCacheCount" : 0.0, + "regions" : 1.0, + "blockCacheHitRatio" : 0.0, + "flushQueueSize" : 0.0, + "fsReadLatencyHistogram_95th_percentile" : 0.0, + "blockCacheHitCount" : 0.0, + "blockCacheHitCachingRatio" : 0.0, + "flushTime_avg_time" : 0.0, + "putRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_min" : 0.0, + "flushTime_num_ops" : 0.0, + "putRequestLatency_median" : 0.0, + "compactionTime_avg_time" : 0.0, + "getRequestLatency_median" : 0.0, + "fsReadLatency_num_ops" : 0.0, + "readRequestsCount" : 13386.15, + "blockCacheSize" : 4845696.0, + "rootIndexSizeKB" : 0.0, + "fsReadLatencyHistogram_std_dev" : 0.0, + "fsReadLatencyHistogram_75th_percentile" : 0.0, + "putRequestLatency_std_dev" : 0.0, + "getRequestLatency_max" : 0.0, + "getRequestLatency_std_dev" : 0.0, + "putRequestLatency_95th_percentile" : 0.0, + "blockCacheMissCount" : 0.0, + "deleteRequestLatency_75th_percentile" : 0.0, + "storefiles" : 0.0, + "fsWriteLatencyHistogram_num_ops" : 0.0, + "flushSize_num_ops" : 0.0, + "putRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_99th_percentile" : 0.0, + "stores" : 1.0, + "fsReadLatencyHistogram_median" : 0.0 + } + }, + "disk" : { + "disk_total" : 0.0, + "disk_free" : 0.0, + "part_max_used" : 0.0 + }, + "cpu" : { + "cpu_speed" : 2659.0, + "cpu_num" : 0.0, + "cpu_wio" : 0.675, + "cpu_idle" : 92.6127778, + "cpu_nice" : 0.0, + "cpu_aidle" : 0.0, + "cpu_system" : 1.85166667, + "cpu_user" : 4.88055556 + }, + "jvm" : { + "memHeapCommittedM" : 0.0, + "logFatal" : 0.0, + "threadsBlocked" : 0.0, + "threadsWaiting" : 25.1083333, + "gcCount" : 1.19304645E8, + "logError" : 0.0, + "logWarn" : 0.0, + "memNonHeapCommittedM" : 42.1007488, + "gcTimeMillis" : 1.19304642E8, + "memNonHeapUsedM" : 0.0, + "logInfo" : 1.19304647E8, + "threadsNew" : 0.0, + "memHeapUsedM" : 0.0, + "threadsTerminated" : 0.0, + "threadsTimedWaiting" : 11.2666667, + "maxMemoryM" : 0.0, + "threadsRunnable" : 0.0 + }, + "load" : { + "load_fifteen" : 0.0, + "load_one" : 0.0, + "load_five" : 0.0 + }, + "memory" : { + "mem_total" : 0.0, + "swap_free" : 0.0, + "mem_buffers" : 485391.389, + "mem_shared" : 0.0, + "mem_cached" : 2576214.31, + "mem_free" : 543601.533, + "swap_total" : 0.0 + }, + "network" : { + "pkts_out" : 18.29375, + "bytes_in" : 0.0, + "bytes_out" : 1883.8725, + "pkts_in" : 315.4695 + } + }, + "component" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_REGIONSERVER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_REGIONSERVER", + "service_name" : "HBASE" + } + } + ] + }, + { + "href" : "http://ambari/clusters/vmc/hosts/ip-10-72-35-220.ec2.internal/host_components/HBASE_REGIONSERVER", + "HostRoles" : { + "cluster_name" : "vmc", + "role_id" : "34", + "state" : "STARTED", + "component_name" : "HBASE_REGIONSERVER", + "host_name" : "ip-10-72-35-220.ec2.internal" + }, + "metrics" : { + "boottime" : 0.0, + "process" : { + "proc_total" : 0.0, + "proc_run" : 0.0 + }, + "rpc" : { + "rpcAuthorizationSuccesses" : 0.0, + "SentBytes" : 0.0, + "rpcAuthorizationFailures" : 0.0, + "ReceivedBytes" : 0.0, + "NumOpenConnections" : 0.0, + "callQueueLen" : 0.0, + "rpcAuthenticationSuccesses" : 0.0, + "RpcQueueTime_num_ops" : 0.0, + "RpcProcessingTime_num_ops" : 0.0, + "RpcProcessingTime_avg_time" : 0.0, + "rpcAuthenticationFailures" : 0.0, + "RpcQueueTime_avg_time" : 0.0 + }, + "ugi" : { + "loginSuccess_num_ops" : 0.0, + "loginFailure_num_ops" : 0.0, + "loginSuccess_avg_time" : 0.0, + "loginFailure_avg_time" : 0.0 + }, + "hbase" : { + "regionserver" : { + "compactionSize_avg_time" : 0.0, + "deleteRequestLatency_min" : 0.0, + "getRequestLatency_95th_percentile" : 0.0, + "getRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_median" : 0.0, + "getRequestLatency_num_ops" : 0.0, + "hlogFileCount" : 0.0, + "requests" : 0.0, + "fsReadLatencyHistogram_num_ops" : 0.0, + "hdfsBlocksLocalityIndex" : 0.0, + "fsWriteLatencyHistogram_std_dev" : 0.0, + "writeRequestsCount" : 0.0, + "flushSize_avg_time" : 0.0, + "fsWriteLatencyHistogram_max" : 0.0, + "deleteRequestLatency_max" : 0.0, + "deleteRequestLatency_std_dev" : 0.0, + "getRequestLatency_75th_percentile" : 0.0, + "fsSyncLatency_num_ops" : 0.0, + "putRequestLatency_max" : 0.0, + "getRequestLatency_mean" : 0.0, + "fsWriteLatencyHistogram_95th_percentile" : 0.0, + "fsSyncLatency_avg_time" : 0.0, + "deleteRequestLatency_num_ops" : 0.0, + "deleteRequestLatency_median" : 0.0, + "compactionTime_num_ops" : 0.0, + "compactionSize_num_ops" : 0.0, + "deleteRequestLatency_mean" : 0.0, + "putRequestLatency_num_ops" : 0.0, + "blockCacheEvictedCount" : 0.0, + "fsReadLatencyHistogram_mean" : 0.0, + "storefileIndexSizeMB" : 0.0, + "fsWriteLatencyHistogram_75th_percentile" : 0.0, + "fsWriteLatency_avg_time" : 0.0, + "fsReadLatencyHistogram_max" : 0.0, + "compactionQueueSize" : 0.0, + "fsWriteLatencyHistogram_min" : 0.0, + "getRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_mean" : 0.0, + "totalStaticBloomSizeKB" : 0.0, + "deleteRequestLatency_99th_percentile" : 0.0, + "putRequestLatency_75th_percentile" : 0.0, + "totalStaticIndexSizeKB" : 0.0, + "putRequestLatency_mean" : 0.0, + "blockCacheFree" : 0.0, + "fsReadLatency_avg_time" : 0.0, + "deleteRequestLatency_95th_percentile" : 0.0, + "fsWriteLatency_num_ops" : 0.0, + "memstoreSizeMB" : 0.0, + "blockCacheCount" : 0.0, + "regions" : 0.0, + "blockCacheHitRatio" : 0.0, + "flushQueueSize" : 0.0, + "fsReadLatencyHistogram_95th_percentile" : 0.0, + "blockCacheHitCount" : 0.0, + "blockCacheHitCachingRatio" : 0.0, + "flushTime_avg_time" : 0.0, + "putRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_min" : 0.0, + "flushTime_num_ops" : 0.0, + "putRequestLatency_median" : 0.0, + "compactionTime_avg_time" : 0.0, + "getRequestLatency_median" : 0.0, + "fsReadLatency_num_ops" : 0.0, + "readRequestsCount" : 0.0, + "blockCacheSize" : 0.0, + "rootIndexSizeKB" : 0.0, + "fsReadLatencyHistogram_std_dev" : 0.0, + "fsReadLatencyHistogram_75th_percentile" : 0.0, + "putRequestLatency_std_dev" : 0.0, + "getRequestLatency_max" : 0.0, + "getRequestLatency_std_dev" : 0.0, + "putRequestLatency_95th_percentile" : 0.0, + "blockCacheMissCount" : 0.0, + "deleteRequestLatency_75th_percentile" : 0.0, + "storefiles" : 0.0, + "fsWriteLatencyHistogram_num_ops" : 0.0, + "flushSize_num_ops" : 0.0, + "putRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_99th_percentile" : 0.0, + "stores" : 0.0, + "fsReadLatencyHistogram_median" : 0.0 + } + }, + "disk" : { + "disk_total" : 0.0, + "disk_free" : 0.0, + "part_max_used" : 0.0 + }, + "cpu" : { + "cpu_speed" : 0.0, + "cpu_num" : 2.0, + "cpu_wio" : 0.0, + "cpu_idle" : 0.0, + "cpu_nice" : 0.0, + "cpu_aidle" : 0.0, + "cpu_system" : 0.0, + "cpu_user" : 0.0 + }, + "jvm" : { + "memHeapCommittedM" : 0.0, + "logFatal" : 0.0, + "threadsBlocked" : 0.0, + "threadsWaiting" : 0.0, + "gcCount" : 0.0, + "logError" : 0.0, + "logWarn" : 0.0, + "memNonHeapCommittedM" : 0.0, + "gcTimeMillis" : 0.0, + "memNonHeapUsedM" : 0.0, + "logInfo" : 0.0, + "threadsNew" : 0.0, + "memHeapUsedM" : 0.0, + "threadsTerminated" : 0.0, + "threadsTimedWaiting" : 7.86944444, + "maxMemoryM" : 0.0, + "threadsRunnable" : 12.0861111 + }, + "load" : { + "load_fifteen" : 0.0, + "load_one" : 0.0, + "load_five" : 0.0 + }, + "memory" : { + "mem_total" : 0.0, + "swap_free" : 0.0, + "mem_buffers" : 274835.867, + "mem_shared" : 0.0, + "mem_cached" : 0.0, + "mem_free" : 0.0, + "swap_total" : 0.0 + }, + "network" : { + "pkts_out" : 0.0, + "bytes_in" : 0.0, + "bytes_out" : 0.0, + "pkts_in" : 0.0 + } + }, + "component" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_REGIONSERVER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_REGIONSERVER", + "service_name" : "HBASE" + } + } + ] + }, + { + "href" : "http://ambari/clusters/vmc/hosts/hostname/host_components/HBASE_REGIONSERVER", + "HostRoles" : { + "cluster_name" : "vmc", + "role_id" : "35", + "state" : "STARTED", + "component_name" : "HBASE_REGIONSERVER", + "host_name" : "hostname" + }, + "metrics" : { + "boottime" : 1.35085737E9, + "process" : { + "proc_total" : 261.0, + "proc_run" : 0.202777778 + }, + "rpc" : { + "rpcAuthorizationSuccesses" : 0.0, + "SentBytes" : 0.0, + "rpcAuthorizationFailures" : 0.0, + "ReceivedBytes" : 0.0, + "NumOpenConnections" : 0.0, + "callQueueLen" : 0.0, + "rpcAuthenticationSuccesses" : 0.0, + "RpcQueueTime_num_ops" : 0.0, + "RpcProcessingTime_num_ops" : 0.0, + "RpcProcessingTime_avg_time" : 0.0, + "rpcAuthenticationFailures" : 0.0, + "RpcQueueTime_avg_time" : 0.0 + }, + "ugi" : { + "loginSuccess_num_ops" : 0.0, + "loginFailure_num_ops" : 0.0, + "loginSuccess_avg_time" : 0.0, + "loginFailure_avg_time" : 0.0 + }, + "hbase" : { + "regionserver" : { + "compactionSize_avg_time" : 0.0, + "deleteRequestLatency_min" : 0.0, + "getRequestLatency_95th_percentile" : 1.112125E7, + "getRequestLatency_min" : 294000.0, + "fsReadLatencyHistogram_99th_percentile" : 1153000.0, + "fsWriteLatencyHistogram_median" : 113000.0, + "getRequestLatency_num_ops" : 28.0, + "hlogFileCount" : 2.0, + "requests" : 0.0, + "fsReadLatencyHistogram_num_ops" : 1.0, + "hdfsBlocksLocalityIndex" : 100.0, + "fsWriteLatencyHistogram_std_dev" : 0.0, + "writeRequestsCount" : 1.0, + "flushSize_avg_time" : 0.0, + "fsWriteLatencyHistogram_max" : 113000.0, + "deleteRequestLatency_max" : 0.0, + "deleteRequestLatency_std_dev" : 0.0, + "getRequestLatency_75th_percentile" : 375500.0, + "fsSyncLatency_num_ops" : 1996190.99, + "putRequestLatency_max" : 0.0, + "getRequestLatency_mean" : 1040142.9, + "fsWriteLatencyHistogram_95th_percentile" : 113000.0, + "fsSyncLatency_avg_time" : 0.0, + "deleteRequestLatency_num_ops" : 0.0, + "deleteRequestLatency_median" : 0.0, + "compactionTime_num_ops" : 0.0, + "compactionSize_num_ops" : 0.0, + "deleteRequestLatency_mean" : 0.0, + "putRequestLatency_num_ops" : 0.0, + "blockCacheEvictedCount" : 0.0, + "fsReadLatencyHistogram_mean" : 1153000.0, + "storefileIndexSizeMB" : 0.0, + "fsWriteLatencyHistogram_75th_percentile" : 0.0, + "fsWriteLatency_avg_time" : 0.0, + "fsReadLatencyHistogram_max" : 1153000.0, + "compactionQueueSize" : 0.0, + "fsWriteLatencyHistogram_min" : 113000.0, + "getRequestLatency_99th_percentile" : 1.8661E7, + "fsWriteLatencyHistogram_mean" : 113000.0, + "totalStaticBloomSizeKB" : 0.0, + "deleteRequestLatency_99th_percentile" : 0.0, + "putRequestLatency_75th_percentile" : 0.0, + "totalStaticIndexSizeKB" : 0.0, + "putRequestLatency_mean" : 0.0, + "blockCacheFree" : 5.85715E8, + "fsReadLatency_avg_time" : 0.0, + "deleteRequestLatency_95th_percentile" : 0.0, + "fsWriteLatency_num_ops" : 4.0, + "memstoreSizeMB" : 0.0, + "blockCacheCount" : 1.0, + "regions" : 1.0, + "blockCacheHitRatio" : 97.0, + "flushQueueSize" : 0.0, + "fsReadLatencyHistogram_95th_percentile" : 1153000.0, + "blockCacheHitCount" : 0.0, + "blockCacheHitCachingRatio" : 97.0, + "flushTime_avg_time" : 0.0, + "putRequestLatency_min" : 0.0, + "fsReadLatencyHistogram_min" : 1153000.0, + "flushTime_num_ops" : 0.0, + "putRequestLatency_median" : 0.0, + "compactionTime_avg_time" : 0.0, + "getRequestLatency_median" : 310500.0, + "fsReadLatency_num_ops" : 1.0, + "readRequestsCount" : 70.0, + "blockCacheSize" : 4846280.0, + "rootIndexSizeKB" : 0.0, + "fsReadLatencyHistogram_std_dev" : 0.0, + "fsReadLatencyHistogram_75th_percentile" : 1153000.0, + "putRequestLatency_std_dev" : 0.0, + "getRequestLatency_max" : 1.8661E7, + "getRequestLatency_std_dev" : 3466455.8, + "putRequestLatency_95th_percentile" : 0.0, + "blockCacheMissCount" : 1.0, + "deleteRequestLatency_75th_percentile" : 0.0, + "storefiles" : 1.0, + "fsWriteLatencyHistogram_num_ops" : 1.0, + "flushSize_num_ops" : 0.0, + "putRequestLatency_99th_percentile" : 0.0, + "fsWriteLatencyHistogram_99th_percentile" : 0.0, + "stores" : 1.0, + "fsReadLatencyHistogram_median" : 1153000.0 + } + }, + "disk" : { + "disk_total" : 893.764, + "disk_free" : 845.558, + "part_max_used" : 42.9 + }, + "cpu" : { + "cpu_speed" : 2000.0, + "cpu_num" : 2.0, + "cpu_wio" : 0.0, + "cpu_idle" : 99.9469444, + "cpu_nice" : 0.0, + "cpu_aidle" : 0.0, + "cpu_system" : 0.0244444444, + "cpu_user" : 0.0 + }, + "jvm" : { + "memHeapCommittedM" : 33.8524306, + "logFatal" : 0.0, + "threadsBlocked" : 0.0, + "threadsWaiting" : 12.2638889, + "gcCount" : 1.19304738E8, + "logError" : 0.0, + "logWarn" : 0.0, + "memNonHeapCommittedM" : 35.3826389, + "gcTimeMillis" : 1.19304747E8, + "memNonHeapUsedM" : 0.0, + "logInfo" : 1.2899815E8, + "threadsNew" : 0.0, + "memHeapUsedM" : 22.6797313, + "threadsTerminated" : 0.0, + "threadsTimedWaiting" : 7.54722222, + "maxMemoryM" : 2252.8125, + "threadsRunnable" : 0.0 + }, + "load" : { + "load_fifteen" : 0.0, + "load_one" : 0.00416666667, + "load_five" : 0.00908333333 + }, + "memory" : { + "mem_total" : 7864320.0, + "swap_free" : 0.0, + "mem_buffers" : 260466.489, + "mem_shared" : 0.0, + "mem_cached" : 1054178.51, + "mem_free" : 5277641.9, + "swap_total" : 0.0 + }, + "network" : { + "pkts_out" : 85.3823333, + "bytes_in" : 263.160583, + "bytes_out" : 16061.1182, + "pkts_in" : 2.33475 + } + }, + "component" : [ + { + "href" : "http://ambari/clusters/vmc/services/HBASE/components/HBASE_REGIONSERVER", + "ServiceComponentInfo" : { + "cluster_name" : "vmc", + "component_name" : "HBASE_REGIONSERVER", + "service_name" : "HBASE" + } + } + ] + } + ] + } + ] } ] }
\ No newline at end of file diff --git a/ambari-web/app/controllers/global/cluster_controller.js b/ambari-web/app/controllers/global/cluster_controller.js index c32b683f5d..f7c8a3a140 100644 --- a/ambari-web/app/controllers/global/cluster_controller.js +++ b/ambari-web/app/controllers/global/cluster_controller.js @@ -244,6 +244,8 @@ App.ClusterController = Em.Controller.extend({ var hdfsSvc2 = null; var mrSvc1 = null; var mrSvc2 = null; + var hbaseSvc1 = null; + var hbaseSvc2 = null; metricsJson.items.forEach(function (svc) { if (svc.ServiceInfo.service_name == "HDFS") { hdfsSvc1 = svc; @@ -251,6 +253,9 @@ App.ClusterController = Em.Controller.extend({ if (svc.ServiceInfo.service_name == "MAPREDUCE") { mrSvc1 = svc; } + if (svc.ServiceInfo.service_name == "HBASE") { + hbaseSvc1 = svc; + } }); serviceComponentJson.items.forEach(function (svc) { if (svc.ServiceInfo.service_name == "HDFS") { @@ -259,11 +264,16 @@ App.ClusterController = Em.Controller.extend({ if (svc.ServiceInfo.service_name == "MAPREDUCE") { mrSvc2 = svc; } + if (svc.ServiceInfo.service_name == "HBASE") { + hbaseSvc2 = svc; + } }); var nnC1 = null; var nnC2 = null; var jtC1 = null; var jtC2 = null; + var hbm1 = null; + var hbm2 = null; if (hdfsSvc1) { hdfsSvc1.components.forEach(function (c) { if (c.ServiceComponentInfo.component_name == "NAMENODE") { @@ -292,12 +302,29 @@ App.ClusterController = Em.Controller.extend({ } }); } + if (hbaseSvc1) { + hbaseSvc1.components.forEach(function (c) { + if (c.ServiceComponentInfo.component_name == "HBASE_MASTER") { + hbm1 = c; + } + }); + } + if (hbaseSvc2) { + hbaseSvc2.components.forEach(function (c) { + if (c.ServiceComponentInfo.component_name == "HBASE_MASTER") { + hbm2 = c; + } + }); + } if (nnC1 && nnC2) { nnC1.ServiceComponentInfo = nnC2.ServiceComponentInfo; } if (jtC1 && jtC2) { jtC1.ServiceComponentInfo = jtC2.ServiceComponentInfo; } + if (hbm1 && hbm2) { + hbm1.ServiceComponentInfo = hbm2.ServiceComponentInfo; + } App.servicesMapper.map(metricsJson); self.updateLoadStatus('services'); } diff --git a/ambari-web/app/controllers/main/dashboard.js b/ambari-web/app/controllers/main/dashboard.js index 8f960a3747..172357655c 100644 --- a/ambari-web/app/controllers/main/dashboard.js +++ b/ambari-web/app/controllers/main/dashboard.js @@ -23,22 +23,6 @@ App.MainDashboardController = Em.Controller.extend({ alerts: function(){ return App.router.get('clusterController.alerts'); }.property('App.router.clusterController.alerts'), - data: { - hbase : { - "hbasemaster_addr": "hbasemaster:60010", - "total_regionservers": "1", - "hbasemaster_starttime": 1348935496, - "live_regionservers": 1, - "dead_regionservers": 0, - "regions_in_transition_count": 0, - "chart": [3,7,7,5,5,3,5,3,7], - - "master_server_heap_used": 2348935243, - "master_server_heap_total": 5648935243, - "average_load": 1.4 - } - }, - alertsFilteredBy: 'All', alertsFilter: function(event) { diff --git a/ambari-web/app/mappers/services_mapper.js b/ambari-web/app/mappers/services_mapper.js index 57ffd3b186..21abb1c19e 100644 --- a/ambari-web/app/mappers/services_mapper.js +++ b/ambari-web/app/mappers/services_mapper.js @@ -76,6 +76,19 @@ App.servicesMapper = App.QuickDataMapper.create({ reduces_waiting: 'jobTrackerComponent.host_components[0].metrics.mapred.jobtracker.waiting_reduces', trackers_decommisioned: 'jobTrackerComponent.host_components[0].metrics.mapred.jobtracker.trackers_decommissioned' }, + + hbaseConfig: { + version: 'masterComponent.ServiceComponentInfo.Version', + master_id: 'masterComponent.host_components[0].HostRoles.host_name', + region_servers: 'region_servers', + master_start_time: 'masterComponent.ServiceComponentInfo.MasterStartTime', + master_active_time: 'masterComponent.ServiceComponentInfo.MasterActiveTime', + average_load: 'masterComponent.ServiceComponentInfo.AverageLoad', + regions_in_transition: 'regions_in_transition', + revision: 'masterComponent.ServiceComponentInfo.Revision', + heap_memory_used: 'masterComponent.ServiceComponentInfo.HeapMemoryUsed', + heap_memory_max: 'masterComponent.ServiceComponentInfo.HeapMemoryMax' + }, model2: App.Component, config2: { @@ -127,7 +140,11 @@ App.servicesMapper = App.QuickDataMapper.create({ if(!item.data_nodes){ item.data_nodes = []; } - item.data_nodes.push(component.host_components[0].HostRoles.host_name); + if(component.host_components){ + component.host_components.forEach(function(hc){ + item.data_nodes.push(hc.HostRoles.host_name); + }); + } } }); // Map @@ -178,13 +195,42 @@ App.servicesMapper = App.QuickDataMapper.create({ if(!item.task_trackers){ item.task_trackers = []; } - item.task_trackers.push(component.host_components[0].HostRoles.host_name); + if(component.host_components){ + component.host_components.forEach(function(hc){ + item.task_trackers.push(hc.HostRoles.host_name); + }); + } } }); // Map finalJson = this.parseIt(item, finalConfig); result.push(finalJson); App.store.load(App.MapReduceService, finalJson); + } else if (item && item.ServiceInfo && item.ServiceInfo.service_name == "HBASE") { + // Change the JSON so that it is easy to map + var hbaseConfig = this.hbaseConfig; + item.components.forEach(function (component) { + if (component.ServiceComponentInfo && component.ServiceComponentInfo.component_name == "HBASE_MASTER") { + item.masterComponent = component; + finalConfig = jQuery.extend(finalConfig, hbaseConfig); + var regionsArray = jQuery.parseJSON(component.ServiceComponentInfo.RegionsInTransition); + item.regions_in_transition = regionsArray == null ? 0 : regionsArray.length; + } + if (component.ServiceComponentInfo && component.ServiceComponentInfo.component_name == "HBASE_REGIONSERVER") { + if (!item.region_servers) { + item.region_servers = []; + } + if(component.host_components){ + component.host_components.forEach(function(hc){ + item.region_servers.push(hc.HostRoles.host_name); + }); + } + } + }); + // Map + finalJson = this.parseIt(item, finalConfig); + result.push(finalJson); + App.store.load(App.HBaseService, finalJson); } else { result.push(this.parseIt(item, this.config)); } diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js index c5230c5ede..f21478aa25 100644 --- a/ambari-web/app/messages.js +++ b/ambari-web/app/messages.js @@ -323,14 +323,21 @@ Em.I18n.translations = { 'dashboard.services.mapreduce.jobTrackerUptime':'Job Trackers Uptime', 'dashboard.services.mapreduce.chart.label':'Jobs Running', - 'dashboard.services.hbase.summary':'{0} of {1} region servers up, {2} average load', - 'dashboard.services.hbase.masterServerHeap':'Master Server Heap', - 'dashboard.services.hbase.masterServerHeap.summary':'{0} of {1} ({2}% used)', + 'dashboard.services.hbase.summary':'{0} region servers with {1} average load', + 'dashboard.services.hbase.masterServer':'HBase Master', + 'dashboard.services.hbase.masterServerHeap':'Master Heap', + 'dashboard.services.hbase.masterServerHeap.summary':'{0} / {1} ({2}% used)', 'dashboard.services.hbase.masterServerUptime':'Master Server Uptime', 'dashboard.services.hbase.averageLoad':'Average Load', + 'dashboard.services.hbase.averageLoadPerServer':'{0} regions per Region Server', 'dashboard.services.hbase.regionServers':'Region Servers', 'dashboard.services.hbase.regionServersSummary':'{0} live / {1} total', 'dashboard.services.hbase.chart.label':'Request Count', + 'dashboard.services.hbase.version':'Version', + 'dashboard.services.hbase.masterWebUI':'Master Web UI', + 'dashboard.services.hbase.regions.transition':'Regions In Transition', + 'dashboard.services.hbase.masterStarted':'Master Started', + 'dashboard.services.hbase.masterActivated':'Master Activated', 'timeRange.presets.1hour':'1h', diff --git a/ambari-web/app/models.js b/ambari-web/app/models.js index 622a0fecc4..8affb97b60 100644 --- a/ambari-web/app/models.js +++ b/ambari-web/app/models.js @@ -31,6 +31,7 @@ require('models/service_audit'); require('models/service_metrics'); require('models/service/hdfs'); require('models/service/mapreduce'); +require('models/service/hbase'); require('models/alert'); require('models/user'); require('models/pagination'); diff --git a/ambari-web/app/models/service/hbase.js b/ambari-web/app/models/service/hbase.js new file mode 100644 index 0000000000..5d0e40cfd2 --- /dev/null +++ b/ambari-web/app/models/service/hbase.js @@ -0,0 +1,33 @@ +/** + * 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. + */ + +var App = require('app'); + +App.HBaseService = App.Service.extend({ + version: DS.attr('string'), + master: DS.belongsTo('App.Host'), + regionServers: DS.hasMany('App.Host'), + masterStartTime: DS.attr('number'), + masterActiveTime: DS.attr('number'), + averageLoad: DS.attr('number'), + regionsInTransition: DS.attr('number'), + revision: DS.attr('string'), + heapMemoryUsed: DS.attr('number'), + heapMemoryMax: DS.attr('number') +}); + +App.HBaseService.FIXTURES = []; diff --git a/ambari-web/app/routes/main.js b/ambari-web/app/routes/main.js index 291586dede..ff77422dc6 100644 --- a/ambari-web/app/routes/main.js +++ b/ambari-web/app/routes/main.js @@ -313,6 +313,10 @@ module.exports = Em.Route.extend({ parent.deactivateChildViews(); event.view.set('active', "active"); router.transitionTo(event.context); + }, + showDetails:function (router, event) { + router.get('mainHostDetailsController').setBack(true); + router.transitionTo('hostDetails.index', event.context) } }), showService:Em.Router.transitionTo('service'), diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less index ee011fc807..ce9fc9e32d 100644 --- a/ambari-web/app/styles/application.less +++ b/ambari-web/app/styles/application.less @@ -519,7 +519,7 @@ a:focus { position: absolute; overflow: visible; // for quick links text-align: center; - width: 200px; + width: 180px; height: 200px; .chart-container{ .chart-x-axis{ diff --git a/ambari-web/app/templates/main/dashboard/service/hbase.hbs b/ambari-web/app/templates/main/dashboard/service/hbase.hbs index 5ed390806d..90b465ebe4 100644 --- a/ambari-web/app/templates/main/dashboard/service/hbase.hbs +++ b/ambari-web/app/templates/main/dashboard/service/hbase.hbs @@ -16,6 +16,7 @@ * limitations under the License. }} +{{#unless view.showOnlyRows}} <div class="clearfix"> <div class="name span2"> {{view App.MainDashboardServiceHealthView serviceBinding="view.service"}} @@ -30,49 +31,60 @@ </div> <table class="table no-borders"> <tbody> - - <!-- Master Server Heap --> +{{/unless}} + <!-- HBase Master Server --> <tr> - <td>{{t dashboard.services.hbase.masterServerHeap}}</td> - <td>{{view.masterServerHeapSummary}}</td> + <td>{{t dashboard.services.hbase.masterServer}}</td> + <td><a href="#" {{action showDetails view.service.master}}>{{view.service.master.hostName}}</a></td> </tr> - - <!-- Average load --> - <tr> - <td>{{t dashboard.services.hbase.averageLoad}}</td> - <td>{{view.data.average_load}}</td> - </tr> - - <!-- Region Servers --> + <!-- RegionServers --> <tr> <td>{{t dashboard.services.hbase.regionServers}}</td> - <td>{{view.regionServers}}</td> + <td><a href="#" {{action filterHosts view.regionServerComponent}}>{{view.service.regionServers.length}} {{t dashboard.services.hbase.regionServers}}</a></td> </tr> - - <!-- Master Server Uptime --> + <!-- Version --> <tr> - <td>{{t dashboard.services.hbase.masterServerUptime}}</td> - <td>{{view.masterServerUptime}}</td> + <td>{{t dashboard.services.hbase.version}}</td> + <td>{{view.service.version}} {{view.service.revision}}</td> </tr> - - <!-- Hosts --> + <!-- HBaseMaster Web UI --> <tr> - <td>{{t dashboard.services.hosts}}</td> - <td> - {{#each component in view.service.components}} - {{#if component.type}} - <a href="#" {{action selectHost component.host}}>{{component.displayName}}</a>, - {{else}} - <a href="#" {{action filterHosts component}}>{{component.displayName}}</a> - {{/if}} - {{/each}} + <td>{{t dashboard.services.hbase.masterWebUI}}</td> + <td><a {{bindAttr href="view.hbaseMasterWebUrl"}}>{{view.service.master.hostName}}:60010</a> </td> </tr> + <!-- Regions in Transition --> + <tr> + <td>{{t dashboard.services.hbase.regions.transition}}</td> + <td>{{view.service.regionsInTransition}}</td> + </tr> + <!-- HBase Master Started Time --> + <tr> + <td>{{t dashboard.services.hbase.masterStarted}}</td> + <td>{{view.masterStartedTime}}</td> + </tr> + <!-- HBase Master Activated Time --> + <tr> + <td>{{t dashboard.services.hbase.masterActivated}}</td> + <td>{{view.masterStartedTime}}</td> + </tr> + <!-- Average Load --> + <tr> + <td>{{t dashboard.services.hbase.averageLoad}}</td> + <td>{{view.averageLoad}}</td> + </tr> + <!-- Master Server Heap --> + <tr> + <td>{{t dashboard.services.hbase.masterServerHeap}}</td> + <td>{{view.masterServerHeapSummary}}</td> + </tr> + +{{#unless view.showOnlyRows}} </tbody> </table> <div class="dashboard-mini-chart"> - {{view view.Chart}} - <div class="chartLabel">{{t dashboard.services.hbase.chart.label}}</div> + {{view App.ChartServiceMetricsHBASE_RegionServerReadWriteRequests}} + {{#if view.service.quickLinks.length}} {{#view App.QuickViewLinks contentBinding="view.service"}} <div class="btn-group"> @@ -89,3 +101,4 @@ {{/view}} {{/if}} </div> +{{/unless}}
\ No newline at end of file diff --git a/ambari-web/app/templates/main/service/info/summary.hbs b/ambari-web/app/templates/main/service/info/summary.hbs index f6b00f8c95..3abb1f786e 100644 --- a/ambari-web/app/templates/main/service/info/summary.hbs +++ b/ambari-web/app/templates/main/service/info/summary.hbs @@ -45,6 +45,7 @@ {{#unless view.serviceStatus.zookeeper}} {{#unless view.serviceStatus.hdfs}} {{#unless view.serviceStatus.mapreduce}} + {{#unless view.serviceStatus.hbase}} {{#each component in controller.content.components}} <tr> {{#if component.isMaster}} @@ -61,6 +62,7 @@ {{/unless}} {{/unless}} {{/unless}} + {{/unless}} {{#if view.serviceStatus.hdfs}} {{view App.MainDashboardServiceHdfsView showOnlyRows=true serviceBinding="view.service"}} {{/if}} @@ -68,43 +70,7 @@ {{view App.MainDashboardServiceMapreduceView showOnlyRows=true serviceBinding="view.service"}} {{/if}} {{#if view.serviceStatus.hbase}} - <tr> - <td>{{t services.service.summary.version}}</td> - <td>{{view.attributes.version}}</td> - </tr> - <tr> - <td>{{t services.service.summary.hbaseMaster}}</td> - <td><a {{bindAttr href="view.attributes.hbasemaster_addr"}}>{{view.attributes.hbasemaster_addr}}</a></td> - </tr> - <tr> - <td>{{t services.service.summary.regionServerCount}}</td> - <td> - <a href="javascript:void(null)">{{view.attributes.live_regionservers}} live</a> / <a - href="javascript:void(null)">{{view.attributes.dead_regionservers}} dead</a> - </td> - </tr> - <tr> - <td>{{t services.service.summary.regionInTransition}}</td> - <td>{{view.attributes.regions_in_transition_count}}</td> - </tr> - <tr> - <td>{{t services.service.summary.masterStarted}}</td> - <td>{{view.attributes.start_time.d}}day {{view.attributes.start_time.h}}hr {{view.attributes.start_time.m}}min</td> - </tr> - <tr> - <td>{{t services.service.summary.masterActivated}}</td> - <td>{{view.attributes.active_time.d}}day {{view.attributes.active_time.h}}hr {{view.attributes.active_time.m}}min</td> - </tr> - <tr> - <td>{{t services.service.summary.averageLoad}}</td> - <td>{{view.attributes.average_load}} regions per RegionServer</td> - </tr> - <tr> - <td>{{t services.service.summary.masterHeap}}</td> - <td>{{view.attributes.memory_heap_used}} / {{view.attributes.memory_heap_max}} ({{view.attributes.memory_heap_percent_used}} - used) - </td> - </tr> + {{view App.MainDashboardServiceHbaseView showOnlyRows=true serviceBinding="view.service"}} {{/if}} {{#if view.serviceStatus.zookeeper}} <tr> diff --git a/ambari-web/app/views/main/dashboard.js b/ambari-web/app/views/main/dashboard.js index 3aa3f42289..872e78a508 100644 --- a/ambari-web/app/views/main/dashboard.js +++ b/ambari-web/app/views/main/dashboard.js @@ -37,6 +37,7 @@ App.MainDashboardView = Em.View.extend({ break; case "HBASE": vName = App.MainDashboardServiceHbaseView; + item2 = App.HBaseService.find(item.get('id')); break; case "HIVE": vName = App.MainDashboardServiceHiveView ; diff --git a/ambari-web/app/views/main/dashboard/service/hbase.js b/ambari-web/app/views/main/dashboard/service/hbase.js index a6a4308e45..5b44c0093e 100644 --- a/ambari-web/app/views/main/dashboard/service/hbase.js +++ b/ambari-web/app/views/main/dashboard/service/hbase.js @@ -1,63 +1,58 @@ /** - * 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 - * + * 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. + * 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. */ var App = require('app'); App.MainDashboardServiceHbaseView = App.MainDashboardServiceView.extend({ - templateName:require('templates/main/dashboard/service/hbase'), - serviceName:'hbase', - - Chart:App.ChartLinearView.extend({ - data:function () { - return this.get('_parentView.data.chart'); - }.property('_parentView.data.chart') - }), - - masterServerHeapSummary:function () { - var percent = this.get('data.master_server_heap_total') > 0 - ? 100 * this.get('data.master_server_heap_used') / this.get('data.master_server_heap_total') - : 0; - - return this.t('dashboard.services.hbase.masterServerHeap.summary').format( - this.get('data.master_server_heap_used').bytesToSize(1, 'parseFloat'), - this.get('data.master_server_heap_total').bytesToSize(1, 'parseFloat'), - percent.toFixed(1) - ); - }.property('data'), - - summaryHeader:function () { - return this.t("dashboard.services.hbase.summary").format( - this.get('data.live_regionservers'), - this.get('data.total_regionservers'), - this.get('data.average_load') - ); - }.property('data'), - - regionServers:function () { - return this.t('dashboard.services.hbase.regionServersSummary').format( - this.get('data.live_regionservers'), this.get('data.total_regionservers') - ); - - }.property('data'), - - masterServerUptime:function () { - var uptime = this.get('data.hbasemaster_starttime'); - var formatted = uptime.toDaysHoursMinutes(); + templateName: require('templates/main/dashboard/service/hbase'), + serviceName: 'hbase', + + masterServerHeapSummary: function () { + var heapUsed = this.get('service').get('heapMemoryUsed'); + var heapMax = this.get('service').get('heapMemoryMax'); + var percent = heapMax > 0 ? 100 * heapUsed / heapMax : 0; + return this.t('dashboard.services.hbase.masterServerHeap.summary').format(heapUsed.bytesToSize(1, "parseFloat"), heapMax.bytesToSize(1, "parseFloat"), percent.toFixed(1)); + }.property('service'), + + summaryHeader: function () { + return this.t("dashboard.services.hbase.summary").format(this.get('service.regionServers.length'), this.get('service.averageLoad')); + }.property('service'), + + hbaseMasterWebUrl: function () { + return "http://" + this.get('service').get('master').get('hostName') + ":60010"; + }.property('service.master'), + + averageLoad: function () { + return this.t('dashboard.services.hbase.averageLoadPerServer').format(this.get('service.averageLoad')); + }.property("service"), + + masterStartedTime: function () { + var uptime = this.get('service').get('masterStartTime'); + var formatted = (new Date().getTime() - uptime).toDaysHoursMinutes(); return this.t('dashboard.services.uptime').format(formatted.d, formatted.h, formatted.m); - }.property("data") + }.property("service"), + + masterActivatedTime: function () { + var uptime = this.get('service').get('masterActiveTime'); + var formatted = (new Date().getTime() - uptime).toDaysHoursMinutes(); + return this.t('dashboard.services.uptime').format(formatted.d, formatted.h, formatted.m); + }.property("service"), + + regionServerComponent: function () { + return App.Component.find().findProperty('componentName', 'HBASE_REGIONSERVER'); + }.property('components') });
\ No newline at end of file diff --git a/ambari-web/app/views/main/dashboard/service/mapreduce.js b/ambari-web/app/views/main/dashboard/service/mapreduce.js index 0eed8616f4..3bb0fc27ed 100644 --- a/ambari-web/app/views/main/dashboard/service/mapreduce.js +++ b/ambari-web/app/views/main/dashboard/service/mapreduce.js @@ -95,7 +95,7 @@ App.MainDashboardServiceMapreduceView = App.MainDashboardServiceView.extend({ var mapSlots = this.get('service').get('mapSlots'); var reduceSlots = this.get('service').get('reduceSlots'); var liveNodeCount = this.get('service').get('aliveTrackers').get('length'); - var avg = (mapSlots + reduceSlots)/liveNodeCount; + var avg = (mapSlots + reduceSlots) / liveNodeCount; return this.t('dashboard.services.mapreduce.slotCapacitySummary').format(mapSlots, reduceSlots, avg); }.property('service'), diff --git a/ambari-web/app/views/main/service/info/summary.js b/ambari-web/app/views/main/service/info/summary.js index 184aea898f..882f065f39 100644 --- a/ambari-web/app/views/main/service/info/summary.js +++ b/ambari-web/app/views/main/service/info/summary.js @@ -47,6 +47,9 @@ App.MainServiceInfoSummaryView = Em.View.extend({ case 'mapreduce': svc = App.MapReduceService.find().objectAt(0); break; + case 'hbase': + svc = App.HBaseService.find().objectAt(0); + break; default: break; } @@ -141,25 +144,8 @@ App.MainServiceInfoSummaryView = Em.View.extend({ console.log('load ', serviceName, ' info'); this.set('oldServiceName', serviceName); serviceName = serviceName.toLowerCase(); - if(serviceName=='hbase'){ - jQuery.getJSON('data/services/summary/' + serviceName + '.json', function (data) { - if (data[serviceName]) { - var summary = data[serviceName]; - if (serviceName == 'hbase') { - summary['memory_heap_percent_used'] = summary['memory_heap_used'].countPercentageRatio(summary['memory_heap_max']); - summary['memory_heap_used'] = summary['memory_heap_used'].bytesToSize(2, 'parseFloat'); - summary['memory_heap_max'] = summary['memory_heap_max'].bytesToSize(2, 'parseFloat'); - summary['start_time'] = summary['start_time'].toDaysHoursMinutes(); - summary['active_time'] = summary['active_time'].toDaysHoursMinutes(); - } - summaryView.set('attributes', summary); - } - }) - } }.observes('serviceName'), - - didInsertElement: function () { // We have to make the height of the Alerts section // match the height of the Summary section. |