Index: /branches/amp_4_0/platform/config/telegraf/ag.toml
===================================================================
--- /branches/amp_4_0/platform/config/telegraf/ag.toml	(revision 2706)
+++ /branches/amp_4_0/platform/config/telegraf/ag.toml	(working copy)
@@ -1,6 +1,6 @@
 [[inputs.snmp]]
 agents = []
-community = "$YTINUMMOC"
+community = "public"
 name = "an_device_metrics"
 timeout = "2s"
 
@@ -13,7 +13,7 @@
 oid = ".1.3.6.1.4.1.7564.30.4.0"
 
 [[inputs.snmp.field]]
-name = "totalOpenSSLConns"
+name = "total_openssl_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.1.0"
 
 [[inputs.snmp.field]]
@@ -32,307 +32,135 @@
 name = "total_out"
 oid = ".1.3.6.1.4.1.7564.23.3.0"
 
-
 [[inputs.snmp.table]]
 name = "ag_virtual_site_stats"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Id"
+name = "id"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.2"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "IP"
+name = "ip"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.17"
 
 [[inputs.snmp.table.field]]
-name = "ActiveSessions"
+name = "active_sessions"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.3"
 
 [[inputs.snmp.table.field]]
-name = "SuccessLogin"
+name = "success_login"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.4"
 
 [[inputs.snmp.table.field]]
-name = "FailureLogin"
+name = "failure_login"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.5"
 
 [[inputs.snmp.table.field]]
-name = "ErrorLogin"
+name = "error_login"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.6"
 
 [[inputs.snmp.table.field]]
-name = "SuccessLogout"
+name = "success_logout"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.7"
 
 [[inputs.snmp.table.field]]
-name = "ClientBytesIn"
+name = "client_bytes_in"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.8"
 
 [[inputs.snmp.table.field]]
-name = "ClientBytesOut"
+name = "client_bytes_out"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.9"
 
 [[inputs.snmp.table.field]]
-name = "LockedLogin"
+name = "locked_login"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.15"
 
 [[inputs.snmp.table.field]]
-name = "RejectedLogin"
+name = "rejected_login"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.16"
 
 [[inputs.snmp.table.field]]
-name = "ServerBytesIn"
+name = "server_bytes_in"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.19"
 
 [[inputs.snmp.table.field]]
-name = "ServerBytesOut"
+name = "server_bytes_out"
 oid = ".1.3.6.1.4.1.7564.31.1.2.1.20"
 
-
 [[inputs.snmp.table]]
 name = "ag_vpn_stats"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Id"
+name = "id"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.2"
 
 [[inputs.snmp.table.field]]
-name = "TunnelsOpen"
+name = "tunnels_open"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.3"
 
 [[inputs.snmp.table.field]]
-name = "TunnelsEst"
+name = "tunnels_est"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.4"
 
 [[inputs.snmp.table.field]]
-name = "TunnelsRejected"
+name = "tunnels_rejected"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.5"
 
 [[inputs.snmp.table.field]]
-name = "TunnelsTerminated"
+name = "tunnels_terminated"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.6"
 
 [[inputs.snmp.table.field]]
-name = "BytesIn"
+name = "bytes_in"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.7"
 
 [[inputs.snmp.table.field]]
-name = "BytesOut"
+name = "bytes_out"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.8"
 
 [[inputs.snmp.table.field]]
-name = "UnauthPacketsIn"
+name = "unauth_packets_in"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.9"
 
 [[inputs.snmp.table.field]]
-name = "clientAppBytesIn"
+name = "client_app_bytes_in"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.10"
 
 [[inputs.snmp.table.field]]
-name = "clientAppBytesOut"
+name = "client_app_bytes_out"
 oid = ".1.3.6.1.4.1.7564.32.1.2.1.11"
 
-
 [[inputs.snmp.table]]
 name = "ag_web_stats"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Id"
+name = "id"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.2"
 
 [[inputs.snmp.table.field]]
-name = "AuthorizedReq"
+name = "authorized_req"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.3"
 
 [[inputs.snmp.table.field]]
-name = "UnauthorizedReq"
+name = "unauthorized_req"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.4"
 
 [[inputs.snmp.table.field]]
-name = "ClientBytesIn"
+name = "client_bytes_in"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.5"
 
 [[inputs.snmp.table.field]]
-name = "ClientBytesOut"
+name = "client_bytes_out"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.6"
 
 [[inputs.snmp.table.field]]
-name = "ServerBytesIn"
+name = "server_bytes_in"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.7"
 
 [[inputs.snmp.table.field]]
-name = "ServerBytesOut"
+name = "server_bytes_out"
 oid = ".1.3.6.1.4.1.7564.33.1.2.1.8"
-[[inputs.snmp]]
-agents = []
-community = "$YTINUMMOC"
-name = "an_device_metrics"
-timeout = "2s"
-
-[[inputs.snmp.field]]
-name = "cpu_usage"
-oid = ".1.3.6.1.4.1.7564.30.1.0"
-
-[[inputs.snmp.field]]
-name = "net_mem_usage"
-oid = ".1.3.6.1.4.1.7564.30.4.0"
-
-[[inputs.snmp.field]]
-name = "totalOpenSSLConns"
-oid = ".1.3.6.1.4.1.7564.20.2.1.0"
-
-[[inputs.snmp.field]]
-name = "connections"
-oid = ".1.3.6.1.4.1.7564.30.2.0"
-
-[[inputs.snmp.field]]
-name = "requests"
-oid = ".1.3.6.1.4.1.7564.30.3.0"
-
-[[inputs.snmp.field]]
-name = "total_in"
-oid = ".1.3.6.1.4.1.7564.23.2.0"
-
-[[inputs.snmp.field]]
-name = "total_out"
-oid = ".1.3.6.1.4.1.7564.23.3.0"
-
-
-[[inputs.snmp.table]]
-name = "ag_virtual_site_stats"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Id"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.2"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "IP"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.17"
-
-[[inputs.snmp.table.field]]
-name = "ActiveSessions"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.3"
-
-[[inputs.snmp.table.field]]
-name = "SuccessLogin"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.4"
-
-[[inputs.snmp.table.field]]
-name = "FailureLogin"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.5"
-
-[[inputs.snmp.table.field]]
-name = "ErrorLogin"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.6"
-
-[[inputs.snmp.table.field]]
-name = "SuccessLogout"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.7"
-
-[[inputs.snmp.table.field]]
-name = "ClientBytesIn"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.8"
-
-[[inputs.snmp.table.field]]
-name = "ClientBytesOut"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.9"
-
-[[inputs.snmp.table.field]]
-name = "LockedLogin"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.15"
-
-[[inputs.snmp.table.field]]
-name = "RejectedLogin"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.16"
-
-[[inputs.snmp.table.field]]
-name = "ServerBytesIn"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.19"
-
-[[inputs.snmp.table.field]]
-name = "ServerBytesOut"
-oid = ".1.3.6.1.4.1.7564.31.1.2.1.20"
-
-
-[[inputs.snmp.table]]
-name = "ag_vpn_stats"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Id"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.2"
-
-[[inputs.snmp.table.field]]
-name = "TunnelsOpen"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.3"
-
-[[inputs.snmp.table.field]]
-name = "TunnelsEst"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.4"
-
-[[inputs.snmp.table.field]]
-name = "TunnelsRejected"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.5"
-
-[[inputs.snmp.table.field]]
-name = "TunnelsTerminated"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.6"
-
-[[inputs.snmp.table.field]]
-name = "BytesIn"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.7"
-
-[[inputs.snmp.table.field]]
-name = "BytesOut"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.8"
-
-[[inputs.snmp.table.field]]
-name = "UnauthPacketsIn"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.9"
-
-[[inputs.snmp.table.field]]
-name = "clientAppBytesIn"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.10"
-
-[[inputs.snmp.table.field]]
-name = "clientAppBytesOut"
-oid = ".1.3.6.1.4.1.7564.32.1.2.1.11"
-
-
-[[inputs.snmp.table]]
-name = "ag_web_stats"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Id"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.2"
-
-[[inputs.snmp.table.field]]
-name = "AuthorizedReq"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.3"
-
-[[inputs.snmp.table.field]]
-name = "UnauthorizedReq"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.4"
-
-[[inputs.snmp.table.field]]
-name = "ClientBytesIn"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.5"
-
-[[inputs.snmp.table.field]]
-name = "ClientBytesOut"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.6"
-
-[[inputs.snmp.table.field]]
-name = "ServerBytesIn"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.7"
-
-[[inputs.snmp.table.field]]
-name = "ServerBytesOut"
-oid = ".1.3.6.1.4.1.7564.33.1.2.1.8"
Index: /branches/amp_4_0/platform/config/telegraf/apv.toml
===================================================================
--- /branches/amp_4_0/platform/config/telegraf/apv.toml	(revision 2706)
+++ /branches/amp_4_0/platform/config/telegraf/apv.toml	(working copy)
@@ -1,6 +1,6 @@
 [[inputs.snmp]]
 agents = []
-community = "$YTINUMMOC"
+community = "public"
 name = "an_device_metrics"
 timeout = "2s"
 
@@ -17,7 +17,7 @@
 oid = ".1.3.6.1.4.1.7564.4.2.0"
 
 [[inputs.snmp.field]]
-name = "totalOpenSSLConns"
+name = "totalopensslconns"
 oid = ".1.3.6.1.4.1.7564.20.2.1.0"
 
 [[inputs.snmp.field]]
@@ -39,16 +39,16 @@
 
 [[inputs.snmp]]
 agents = []
-community = "$YTINUMMOC"
+community = "public"
 name = "an_device_performance"
 timeout = "2s"
 
 [[inputs.snmp.field]]
-name = "sslAECoreUtilization"
+name = "sslaecoreutilization"
 oid = ".1.3.6.1.4.1.7564.30.9.0"
 
 [[inputs.snmp.field]]
-name = "sslSECoreUtilization"
+name = "sslsecoreutilization"
 oid = ".1.3.6.1.4.1.7564.30.10.0"
 
 
@@ -68,581 +68,265 @@
 name = "used"
 oid = ".1.3.6.1.2.1.25.2.3.1.6"
 
+
 [[inputs.snmp.table]]
 name = "apv_virtual_stats"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "ServerId"
+name = "serverid"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.2"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Addr"
+name = "addr"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.3"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Port"
+name = "port"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.4"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Protocol"
+name = "protocol"
 oid = ".1.3.6.1.4.1.7564.19.1.2.2.1.3"
 
 [[inputs.snmp.table.field]]
-name = "URLHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.5"
-
-[[inputs.snmp.table.field]]
-name = "HostnameHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.6"
-
-[[inputs.snmp.table.field]]
-name = "PerstntCookieHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.7"
-
-[[inputs.snmp.table.field]]
-name = "QosCookieHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.8"
-
-[[inputs.snmp.table.field]]
-name = "DefaultHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.9"
-
-[[inputs.snmp.table.field]]
-name = "PerstntURLHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.10"
-
-[[inputs.snmp.table.field]]
-name = "StaticHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.11"
-
-[[inputs.snmp.table.field]]
-name = "QosNetworkHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.12"
-
-[[inputs.snmp.table.field]]
-name = "QosURLHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.13"
-
-[[inputs.snmp.table.field]]
-name = "BackupHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.14"
-
-[[inputs.snmp.table.field]]
-name = "CacheHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.15"
-
-[[inputs.snmp.table.field]]
-name = "RegexHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.16"
-
-[[inputs.snmp.table.field]]
-name = "RCookieHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.17"
-
-[[inputs.snmp.table.field]]
-name = "ICookieHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.18"
-
-[[inputs.snmp.table.field]]
-name = "ConnCnt"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.19"
-
-[[inputs.snmp.table.field]]
-name = "QosClientPortHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.22"
-
-[[inputs.snmp.table.field]]
-name = "QosBodyHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.23"
-
-[[inputs.snmp.table.field]]
-name = "HeaderHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.24"
-
-[[inputs.snmp.table.field]]
-name = "HashURLHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.25"
-
-[[inputs.snmp.table.field]]
-name = "RedirectHits"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.26"
-
-[[inputs.snmp.table.field]]
-name = "ConnPerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.31"
-
-[[inputs.snmp.table.field]]
-name = "InBytePerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.32"
-
-[[inputs.snmp.table.field]]
-name = "OutBytePerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.33"
-
-[[inputs.snmp.table.field]]
-name = "InPacketPerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.34"
-
-[[inputs.snmp.table.field]]
-name = "OutPacketPerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.35"
-
-[[inputs.snmp.table.field]]
 is_tag = true
-name = "HealthStatus"
+name = "healthstatus"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.36"
-
-
-[[inputs.snmp.table]]
-name = "apv_real_stats"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "realServerId"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.2"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Addr"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.3"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Port"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.4"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Protocol"
-oid = ".1.3.6.1.4.1.7564.19.1.1.2.1.3"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Status"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.8"
-
-[[inputs.snmp.table.field]]
-name = "rsCntOfReq"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.5"
-
-[[inputs.snmp.table.field]]
-name = "rsConnCnt"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.6"
-
-[[inputs.snmp.table.field]]
-name = "rsTotalHits"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.7"
-
-[[inputs.snmp.table.field]]
-name = "rsConnPerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.13"
-
-[[inputs.snmp.table.field]]
-name = "rsInBytePerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.14"
-
-[[inputs.snmp.table.field]]
-name = "rsOutBytePerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.15"
-
-[[inputs.snmp.table.field]]
-name = "rsInPacketPerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.16"
-
-[[inputs.snmp.table.field]]
-name = "rsOutPacketPerSec"
-oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.17"
-
-[[inputs.snmp.table]]
-name = "apv_llb_stats"
-
-[[inputs.snmp.table.field]]
-name = "linkIndex"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.1"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "linkName"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.2"
-
-[[inputs.snmp.table.field]]
-name = "linkGateway"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.3"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "linkStatus"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.4"
-
-[[inputs.snmp.table.field]]
-name = "linkRespTime"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.5"
-
-[[inputs.snmp.table.field]]
-name = "linkUpTime"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.6"
-
-[[inputs.snmp.table.field]]
-name = "linkDownTime"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.7"
-
-[[inputs.snmp.table.field]]
-name = "linkDownCount"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.8"
-
-[[inputs.snmp.table.field]]
-name = "linkDownEvent"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.9"
-
-[[inputs.snmp.table.field]]
-name = "linkBandwidIn"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.10"
-
-[[inputs.snmp.table.field]]
-name = "linkBandwidOut"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.11"
 
 [[inputs.snmp.table.field]]
-name = "linkThresh"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.12"
-
-[[inputs.snmp.table.field]]
-name = "linkHits"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.13"
-
-[[inputs.snmp.table.field]]
-name = "linkConn"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.14"
-
-[[inputs.snmp.table.field]]
-name = "linkUsage"
-oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.15"
-
-[[inputs.snmp]]
-agents = []
-community = "$YTINUMMOC"
-name = "an_device_metrics"
-timeout = "2s"
-
-[[inputs.snmp.field]]
-name = "cpu_usage"
-oid = ".1.3.6.1.4.1.7564.30.1.0"
-
-[[inputs.snmp.field]]
-name = "mem_usage"
-oid = ".1.3.6.1.4.1.7564.4.5.0"
-
-[[inputs.snmp.field]]
-name = "net_mem_usage"
-oid = ".1.3.6.1.4.1.7564.4.2.0"
-
-[[inputs.snmp.field]]
-name = "totalOpenSSLConns"
-oid = ".1.3.6.1.4.1.7564.20.2.1.0"
-
-[[inputs.snmp.field]]
-name = "connections"
-oid = ".1.3.6.1.4.1.7564.30.2.0"
-
-[[inputs.snmp.field]]
-name = "requests"
-oid = ".1.3.6.1.4.1.7564.30.3.0"
-
-[[inputs.snmp.field]]
-name = "total_in"
-oid = ".1.3.6.1.4.1.7564.23.2.0"
-
-[[inputs.snmp.field]]
-name = "total_out"
-oid = ".1.3.6.1.4.1.7564.23.3.0"
-
-
-[[inputs.snmp]]
-agents = []
-community = "$YTINUMMOC"
-name = "an_device_performance"
-timeout = "2s"
-
-[[inputs.snmp.field]]
-name = "sslAECoreUtilization"
-oid = ".1.3.6.1.4.1.7564.30.9.0"
-
-[[inputs.snmp.field]]
-name = "sslSECoreUtilization"
-oid = ".1.3.6.1.4.1.7564.30.10.0"
-
-
-[[inputs.snmp.table]]
-name = "an_device_storage"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "prefix"
-oid = ".1.3.6.1.2.1.25.2.3.1.3"
-
-[[inputs.snmp.table.field]]
-name = "size"
-oid = ".1.3.6.1.2.1.25.2.3.1.5"
-
-[[inputs.snmp.table.field]]
-name = "used"
-oid = ".1.3.6.1.2.1.25.2.3.1.6"
-
-[[inputs.snmp.table]]
-name = "apv_virtual_stats"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "ServerId"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.2"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Addr"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.3"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Port"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.4"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "Protocol"
-oid = ".1.3.6.1.4.1.7564.19.1.2.2.1.3"
-
-[[inputs.snmp.table.field]]
-name = "URLHits"
+name = "urlhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.5"
 
 [[inputs.snmp.table.field]]
-name = "HostnameHits"
+name = "hostnamehits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.6"
 
 [[inputs.snmp.table.field]]
-name = "PerstntCookieHits"
+name = "perstntcookiehits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.7"
 
 [[inputs.snmp.table.field]]
-name = "QosCookieHits"
+name = "qoscookiehits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.8"
 
 [[inputs.snmp.table.field]]
-name = "DefaultHits"
+name = "defaulthits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.9"
 
 [[inputs.snmp.table.field]]
-name = "PerstntURLHits"
+name = "perstnturlhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.10"
 
 [[inputs.snmp.table.field]]
-name = "StaticHits"
+name = "statichits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.11"
 
 [[inputs.snmp.table.field]]
-name = "QosNetworkHits"
+name = "qosnetworkhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.12"
 
 [[inputs.snmp.table.field]]
-name = "QosURLHits"
+name = "qosurlhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.13"
 
 [[inputs.snmp.table.field]]
-name = "BackupHits"
+name = "backuphits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.14"
 
 [[inputs.snmp.table.field]]
-name = "CacheHits"
+name = "cachehits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.15"
 
 [[inputs.snmp.table.field]]
-name = "RegexHits"
+name = "regexhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.16"
 
 [[inputs.snmp.table.field]]
-name = "RCookieHits"
+name = "rcookiehits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.17"
 
 [[inputs.snmp.table.field]]
-name = "ICookieHits"
+name = "icookiehits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.18"
 
 [[inputs.snmp.table.field]]
-name = "ConnCnt"
+name = "conncnt"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.19"
 
 [[inputs.snmp.table.field]]
-name = "QosClientPortHits"
+name = "qosclientporthits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.22"
 
 [[inputs.snmp.table.field]]
-name = "QosBodyHits"
+name = "qosbodyhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.23"
 
 [[inputs.snmp.table.field]]
-name = "HeaderHits"
+name = "headerhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.24"
 
 [[inputs.snmp.table.field]]
-name = "HashURLHits"
+name = "hashurlhits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.25"
 
 [[inputs.snmp.table.field]]
-name = "RedirectHits"
+name = "redirecthits"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.26"
 
 [[inputs.snmp.table.field]]
-name = "ConnPerSec"
+name = "connpersec"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.31"
 
 [[inputs.snmp.table.field]]
-name = "InBytePerSec"
+name = "inbytepersec"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.32"
 
 [[inputs.snmp.table.field]]
-name = "OutBytePerSec"
+name = "outbytepersec"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.33"
 
 [[inputs.snmp.table.field]]
-name = "InPacketPerSec"
+name = "inpacketpersec"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.34"
 
 [[inputs.snmp.table.field]]
-name = "OutPacketPerSec"
+name = "outpacketpersec"
 oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.35"
 
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "HealthStatus"
-oid = ".1.3.6.1.4.1.7564.19.2.2.1.1.36"
 
-
+# --- apv_real_stats table ---
 [[inputs.snmp.table]]
 name = "apv_real_stats"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "realServerId"
+name = "index"
+oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.1"
+
+[[inputs.snmp.table.field]]
+is_tag = true
+name = "real_server_id"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.2"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Addr"
+name = "addr"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.3"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Port"
+name = "port"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.4"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Protocol"
+name = "protocol"
 oid = ".1.3.6.1.4.1.7564.19.1.1.2.1.3"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "Status"
+name = "status"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.8"
 
 [[inputs.snmp.table.field]]
-name = "rsCntOfReq"
+name = "rs_cnt_of_req"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.5"
 
 [[inputs.snmp.table.field]]
-name = "rsConnCnt"
+name = "rs_conn_cnt"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.6"
 
 [[inputs.snmp.table.field]]
-name = "rsTotalHits"
+name = "rs_total_hits"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.7"
 
 [[inputs.snmp.table.field]]
-name = "rsConnPerSec"
+name = "rs_conn_per_sec"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.13"
 
 [[inputs.snmp.table.field]]
-name = "rsInBytePerSec"
+name = "rs_in_byte_per_sec"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.14"
 
 [[inputs.snmp.table.field]]
-name = "rsOutBytePerSec"
+name = "rs_out_byte_per_sec"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.15"
 
 [[inputs.snmp.table.field]]
-name = "rsInPacketPerSec"
+name = "rs_in_packet_per_sec"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.16"
 
 [[inputs.snmp.table.field]]
-name = "rsOutPacketPerSec"
+name = "rs_out_packet_per_sec"
 oid = ".1.3.6.1.4.1.7564.19.2.1.1.1.17"
 
+
+# --- apv_llb_stats table ---
 [[inputs.snmp.table]]
 name = "apv_llb_stats"
 
 [[inputs.snmp.table.field]]
-name = "linkIndex"
+name = "linkindex"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.1"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "linkName"
+name = "linkname"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.2"
 
 [[inputs.snmp.table.field]]
-name = "linkGateway"
+name = "linkgateway"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.3"
 
 [[inputs.snmp.table.field]]
 is_tag = true
-name = "linkStatus"
+name = "linkstatus"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.4"
 
 [[inputs.snmp.table.field]]
-name = "linkRespTime"
+name = "linkresptime"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.5"
 
 [[inputs.snmp.table.field]]
-name = "linkUpTime"
+name = "linkuptime"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.6"
 
 [[inputs.snmp.table.field]]
-name = "linkDownTime"
+name = "linkdowntime"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.7"
 
 [[inputs.snmp.table.field]]
-name = "linkDownCount"
+name = "linkdowncount"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.8"
 
 [[inputs.snmp.table.field]]
-name = "linkDownEvent"
+name = "linkdownevent"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.9"
 
 [[inputs.snmp.table.field]]
-name = "linkBandwidIn"
+name = "linkbandwidin"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.10"
 
 [[inputs.snmp.table.field]]
-name = "linkBandwidOut"
+name = "linkbandwidout"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.11"
 
 [[inputs.snmp.table.field]]
-name = "linkThresh"
+name = "linkthresh"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.12"
 
 [[inputs.snmp.table.field]]
-name = "linkHits"
+name = "linkhits"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.13"
 
 [[inputs.snmp.table.field]]
-name = "linkConn"
+name = "linkconn"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.14"
 
 [[inputs.snmp.table.field]]
-name = "linkUsage"
+name = "linkusage"
 oid = ".1.3.6.1.4.1.7564.34.2.1.2.1.15"
-
Index: /branches/amp_4_0/platform/config/telegraf/asf.toml
===================================================================
--- /branches/amp_4_0/platform/config/telegraf/asf.toml	(revision 2706)
+++ /branches/amp_4_0/platform/config/telegraf/asf.toml	(working copy)
@@ -1,6 +1,6 @@
 [[inputs.snmp]]
 agents = []
-community = "$YTINUMMOC"
+community = "public"
 name = "an_device_metrics"
 timeout = "2s"
 
@@ -17,7 +17,7 @@
 oid = ".1.3.6.1.4.1.7564.4.2.0"
 
 [[inputs.snmp.field]]
-name = "totalOpenSSLConns"
+name = "total_openssl_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.1.0"
 
 [[inputs.snmp.field]]
@@ -36,7 +36,6 @@
 name = "total_out"
 oid = ".1.3.6.1.4.1.7564.23.3.0"
 
-
 [[inputs.snmp.table]]
 name = "an_device_storage"
 
@@ -52,746 +51,136 @@
 [[inputs.snmp.table.field]]
 name = "used"
 oid = ".1.3.6.1.2.1.25.2.3.1.6"
-
-[[inputs.snmp.table]]
-name = "asf_ssl_statistics"
-
-[[inputs.snmp.table.field]]
-name = "totalOpenSSLConns"
-oid = ".1.3.6.1.4.1.7564.20.2.1"
-
-[[inputs.snmp.table.field]]
-name = "totalAcceptedConns"
-oid = ".1.3.6.1.4.1.7564.20.2.2"
-
-[[inputs.snmp.table.field]]
-name = "totalRequestedConns"
-oid = ".1.3.6.1.4.1.7564.20.2.3"
-
-
-[[inputs.snmp.table]]
-name = "asf_ssl_host_statistics"
-
-[[inputs.snmp.table.field]]
-name = "sslIndex"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.1"
-
-[[inputs.snmp.table.field]]
-name = "vhostName"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.2"
-
-[[inputs.snmp.table.field]]
-name = "openSSLConns"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.3"
-
-[[inputs.snmp.table.field]]
-name = "acceptedConns"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.4"
-
-[[inputs.snmp.table.field]]
-name = "requestedConns"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.5"
-
-[[inputs.snmp.table.field]]
-name = "resumedSess"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.6"
-
-[[inputs.snmp.table.field]]
-name = "resumableSess"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.7"
-
-[[inputs.snmp.table.field]]
-name = "missSess"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.8"
-
-[[inputs.snmp.table.field]]
-name = "connsPerSec"
-oid = ".1.3.6.1.4.1.7564.20.2.4.1.9"
-
-[[inputs.snmp.table]]
-name = "asf_vip_group_statistics"
-
-[[inputs.snmp.table.field]]
-name = "vipStatus"
-oid = ".1.3.6.1.4.1.7564.22.1"
-
-[[inputs.snmp.table.field]]
-name = "hostName"
-oid = ".1.3.6.1.4.1.7564.22.2"
-
-[[inputs.snmp.table.field]]
-name = "currentTime"
-oid = ".1.3.6.1.4.1.7564.22.3"
-
-[[inputs.snmp.table.field]]
-name = "totalIPPktsIn"
-oid = ".1.3.6.1.4.1.7564.22.4"
-
-[[inputs.snmp.table.field]]
-name = "totalIPPktsOut"
-oid = ".1.3.6.1.4.1.7564.22.5"
-
-[[inputs.snmp.table.field]]
-name = "totalIPBytesIn"
-oid = ".1.3.6.1.4.1.7564.22.6"
-
-[[inputs.snmp.table.field]]
-name = "totalIPBytesOut"
-oid = ".1.3.6.1.4.1.7564.22.7"
-
-[[inputs.snmp.table]]
-name = "asf_vip_statistics"
-
-[[inputs.snmp.table.field]]
-name = "ipIndex"
-oid = ".1.3.6.1.4.1.7564.22.8.1.1"
-
-[[inputs.snmp.table.field]]
-name = "ipAddress"
-oid = ".1.3.6.1.4.1.7564.22.8.1.2"
-
-[[inputs.snmp.table.field]]
-name = "ipPktsIn"
-oid = ".1.3.6.1.4.1.7564.22.8.1.3"
-
-[[inputs.snmp.table.field]]
-name = "ipBytesIn"
-oid = ".1.3.6.1.4.1.7564.22.8.1.4"
-
-[[inputs.snmp.table.field]]
-name = "ipPktsOut"
-oid = ".1.3.6.1.4.1.7564.22.8.1.5"
-
-[[inputs.snmp.table.field]]
-name = "ipBytesOut"
-oid = ".1.3.6.1.4.1.7564.22.8.1.6"
-
-[[inputs.snmp.table.field]]
-name = "startTime"
-oid = ".1.3.6.1.4.1.7564.22.8.1.7"
-
-[[inputs.snmp.table.field]]
-name = "ipAddrType"
-oid = ".1.3.6.1.4.1.7564.22.8.1.8"
-
-[[inputs.snmp.table]]
-name = "asf_syslog_history"
-
-[[inputs.snmp.table.field]]
-name = "index"
-oid = ".1.3.6.1.4.1.7564.24.2.2.1.1"
-
-[[inputs.snmp.table.field]]
-name = "severity"
-oid = ".1.3.6.1.4.1.7564.24.2.2.1.2"
-
-[[inputs.snmp.table.field]]
-name = "msgText"
-oid = ".1.3.6.1.4.1.7564.24.2.2.1.3"
-
-[[inputs.snmp.table]]
-name = "asf_performance_statistics"
-
-[[inputs.snmp.table.field]]
-name = "cpuUtilization"
-oid = ".1.3.6.1.4.1.7564.30.1"
-
-[[inputs.snmp.table.field]]
-name = "connectionsPerSec"
-oid = ".1.3.6.1.4.1.7564.30.2"
-
-[[inputs.snmp.table.field]]
-name = "requestsPerSec"
-oid = ".1.3.6.1.4.1.7564.30.3"
-
-[[inputs.snmp.table.field]]
-name = "sslCoreUtilization"
-oid = ".1.3.6.1.4.1.7564.30.4"
-
-[[inputs.snmp.table.field]]
-name = "sslAECoreUtilization"
-oid = ".1.3.6.1.4.1.7564.30.5"
-
-[[inputs.snmp.table.field]]
-name = "sslSECoreUtilization"
-oid = ".1.3.6.1.4.1.7564.30.6"
-
-[[inputs.snmp.table]]
-name = "asf_http_service"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceIndex"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.1"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceId"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.2"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceCc"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.3"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceCps"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.4"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceRpsGet"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.5"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceRpsPost"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.6"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceRpsHead"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.7"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceRpsPut"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.8"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceRpsDelete"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.9"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceRpsTotal"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.10"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceAnomalyMethod"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.11"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceAnomalyRequestline"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.12"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceAnomalyHost"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.13"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyConnection"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.14"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceAnomalyContentlength"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.15"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceAnomalyRange"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.16"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundInByte"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.17"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundInPacket"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.18"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundOutByte"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.19"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundOutPacket"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.20"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundInByte"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.21"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundInPacket"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.22"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundOutByte"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.23"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundOutPacket"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.24"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTotal"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.25"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeSource"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.26"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeManBl"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.27"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeDynBl"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.28"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeAcl"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.29"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeDdos"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.30"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeWaf"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.31"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeFilter"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.32"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeAnormaly"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.33"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeParseFail"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.34"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeResource"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.35"
-
-[[inputs.snmp.table.field]]
-name = "httpServiceDropTypeProfile"
-oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.36"
-
-[[inputs.snmp.table]]
-name = "asf_https_service"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceIndex"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.1"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceId"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.2"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceCc"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.3"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceCps"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.4"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceRpsGet"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.5"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceRpsPost"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.6"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceRpsHead"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.7"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceRpsPut"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.8"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceRpsDelete"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.9"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceRpsTotal"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.10"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyMethod"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.11"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyRequestline"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.12"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyHost"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.13"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyConnection"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.14"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyContentlength"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.15"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyRange"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.16"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundInByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.17"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundInPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.18"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundOutByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.19"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundOutPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.20"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundInByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.21"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundInPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.22"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundOutByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.23"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundOutPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.24"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundInByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.25"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundInPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.26"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundOutByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.27"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundOutPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.28"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundInByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.29"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundInPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.30"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundOutByte"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.31"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundOutPackets"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.32"
+name = "alloc_unit"
+oid = ".1.3.6.1.2.1.25.2.3.1.4"
 
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTotal"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.33"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeSource"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.34"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeManBl"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.35"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeDynBl"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.36"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeAcl"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.37"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeDdos"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.38"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeWaf"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.39"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeFilter"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.40"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeAnormaly"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.41"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeParseFail"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.42"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeResource"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.43"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeProfile"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.44"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropTotal"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.45"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropResource"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.46"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropDynBl"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.47"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropAnormalyTotal"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.48"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropMismatch"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.49"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHandshakeVersionMismatch"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.50"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropRecordVersion"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.51"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropRecordType"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.52"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHandshakeType"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.53"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHandshakeLen"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.54"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropEncryptDecrypt"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.55"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHostStop"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.56"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropSendData"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.57"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropBadCipher"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.58"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropSendCard"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.59"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropNoRandom"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.60"
-
-[[inputs.snmp.table.field]]
-name = "httpsServiceSslDropBigNumberOperationFailed"
-oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.61"
-
-
-[[inputs.snmp]]
-agents = []
-community = "$YTINUMMOC"
-name = "an_device_metrics"
-timeout = "2s"
-
-[[inputs.snmp.field]]
-name = "cpu_usage"
-oid = ".1.3.6.1.4.1.7564.30.1.0"
-
-[[inputs.snmp.field]]
-name = "mem_usage"
-oid = ".1.3.6.1.4.1.7564.4.5.0"
-
-[[inputs.snmp.field]]
-name = "net_mem_usage"
-oid = ".1.3.6.1.4.1.7564.4.2.0"
-
-[[inputs.snmp.field]]
-name = "totalOpenSSLConns"
-oid = ".1.3.6.1.4.1.7564.20.2.1.0"
-
-[[inputs.snmp.field]]
-name = "connections"
-oid = ".1.3.6.1.4.1.7564.30.2.0"
-
-[[inputs.snmp.field]]
-name = "requests"
-oid = ".1.3.6.1.4.1.7564.30.3.0"
-
-[[inputs.snmp.field]]
-name = "total_in"
-oid = ".1.3.6.1.4.1.7564.23.2.0"
-
-[[inputs.snmp.field]]
-name = "total_out"
-oid = ".1.3.6.1.4.1.7564.23.3.0"
-
-
 [[inputs.snmp.table]]
-name = "an_device_storage"
-
-[[inputs.snmp.table.field]]
-is_tag = true
-name = "prefix"
-oid = ".1.3.6.1.2.1.25.2.3.1.3"
-
-[[inputs.snmp.table.field]]
-name = "size"
-oid = ".1.3.6.1.2.1.25.2.3.1.5"
-
-[[inputs.snmp.table.field]]
-name = "used"
-oid = ".1.3.6.1.2.1.25.2.3.1.6"
-
-[[inputs.snmp.table]]
 name = "asf_ssl_statistics"
 
 [[inputs.snmp.table.field]]
-name = "totalOpenSSLConns"
+name = "total_openssl_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.1"
 
 [[inputs.snmp.table.field]]
-name = "totalAcceptedConns"
+name = "total_accepted_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.2"
 
 [[inputs.snmp.table.field]]
-name = "totalRequestedConns"
+name = "total_requested_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.3"
 
-
 [[inputs.snmp.table]]
 name = "asf_ssl_host_statistics"
 
 [[inputs.snmp.table.field]]
-name = "sslIndex"
+name = "ssl_index"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.1"
 
 [[inputs.snmp.table.field]]
-name = "vhostName"
+name = "vhost_name"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.2"
 
 [[inputs.snmp.table.field]]
-name = "openSSLConns"
+name = "open_ssl_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.3"
 
 [[inputs.snmp.table.field]]
-name = "acceptedConns"
+name = "accepted_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.4"
 
 [[inputs.snmp.table.field]]
-name = "requestedConns"
+name = "requested_conns"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.5"
 
 [[inputs.snmp.table.field]]
-name = "resumedSess"
+name = "resumed_sess"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.6"
 
 [[inputs.snmp.table.field]]
-name = "resumableSess"
+name = "resumable_sess"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.7"
 
 [[inputs.snmp.table.field]]
-name = "missSess"
+name = "miss_sess"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.8"
 
 [[inputs.snmp.table.field]]
-name = "connsPerSec"
+name = "conns_per_sec"
 oid = ".1.3.6.1.4.1.7564.20.2.4.1.9"
 
 [[inputs.snmp.table]]
 name = "asf_vip_group_statistics"
 
 [[inputs.snmp.table.field]]
-name = "vipStatus"
+name = "vip_status"
 oid = ".1.3.6.1.4.1.7564.22.1"
 
 [[inputs.snmp.table.field]]
-name = "hostName"
+name = "host_name"
 oid = ".1.3.6.1.4.1.7564.22.2"
 
 [[inputs.snmp.table.field]]
-name = "currentTime"
+name = "current_tme"
 oid = ".1.3.6.1.4.1.7564.22.3"
 
 [[inputs.snmp.table.field]]
-name = "totalIPPktsIn"
+name = "total_ip_pkts_in"
 oid = ".1.3.6.1.4.1.7564.22.4"
 
 [[inputs.snmp.table.field]]
-name = "totalIPPktsOut"
+name = "total_ip_pkts_out"
 oid = ".1.3.6.1.4.1.7564.22.5"
 
 [[inputs.snmp.table.field]]
-name = "totalIPBytesIn"
+name = "total_ip_bytes_in"
 oid = ".1.3.6.1.4.1.7564.22.6"
 
 [[inputs.snmp.table.field]]
-name = "totalIPBytesOut"
+name = "total_ip_bytes_out"
 oid = ".1.3.6.1.4.1.7564.22.7"
 
 [[inputs.snmp.table]]
 name = "asf_vip_statistics"
 
 [[inputs.snmp.table.field]]
-name = "ipIndex"
+name = "ip_index"
 oid = ".1.3.6.1.4.1.7564.22.8.1.1"
 
 [[inputs.snmp.table.field]]
-name = "ipAddress"
+name = "ip_address"
 oid = ".1.3.6.1.4.1.7564.22.8.1.2"
 
 [[inputs.snmp.table.field]]
-name = "ipPktsIn"
+name = "ip_pkts_in"
 oid = ".1.3.6.1.4.1.7564.22.8.1.3"
 
 [[inputs.snmp.table.field]]
-name = "ipBytesIn"
+name = "ip_bytes_in"
 oid = ".1.3.6.1.4.1.7564.22.8.1.4"
 
 [[inputs.snmp.table.field]]
-name = "ipPktsOut"
+name = "ip_pkts_out"
 oid = ".1.3.6.1.4.1.7564.22.8.1.5"
 
 [[inputs.snmp.table.field]]
-name = "ipBytesOut"
+name = "ip_bytes_out"
 oid = ".1.3.6.1.4.1.7564.22.8.1.6"
 
 [[inputs.snmp.table.field]]
-name = "startTime"
+name = "start_time"
 oid = ".1.3.6.1.4.1.7564.22.8.1.7"
 
 [[inputs.snmp.table.field]]
-name = "ipAddrType"
+name = "ip_addr_type"
 oid = ".1.3.6.1.4.1.7564.22.8.1.8"
 
 [[inputs.snmp.table]]
 name = "asf_syslog_history"
 
 [[inputs.snmp.table.field]]
-name = "index"
+name = "idx"
 oid = ".1.3.6.1.4.1.7564.24.2.2.1.1"
 
 [[inputs.snmp.table.field]]
@@ -799,428 +188,426 @@
 oid = ".1.3.6.1.4.1.7564.24.2.2.1.2"
 
 [[inputs.snmp.table.field]]
-name = "msgText"
+name = "msg_text"
 oid = ".1.3.6.1.4.1.7564.24.2.2.1.3"
 
 [[inputs.snmp.table]]
 name = "asf_performance_statistics"
 
 [[inputs.snmp.table.field]]
-name = "cpuUtilization"
+name = "cpu_utilization"
 oid = ".1.3.6.1.4.1.7564.30.1"
 
 [[inputs.snmp.table.field]]
-name = "connectionsPerSec"
+name = "connections_per_sec"
 oid = ".1.3.6.1.4.1.7564.30.2"
 
 [[inputs.snmp.table.field]]
-name = "requestsPerSec"
+name = "requests_per_sec"
 oid = ".1.3.6.1.4.1.7564.30.3"
 
 [[inputs.snmp.table.field]]
-name = "sslCoreUtilization"
+name = "ssl_core_utilization"
 oid = ".1.3.6.1.4.1.7564.30.4"
 
 [[inputs.snmp.table.field]]
-name = "sslAECoreUtilization"
+name = "ssl_ae_core_utilization"
 oid = ".1.3.6.1.4.1.7564.30.5"
 
 [[inputs.snmp.table.field]]
-name = "sslSECoreUtilization"
+name = "ssl_se_core_utilization"
 oid = ".1.3.6.1.4.1.7564.30.6"
 
 [[inputs.snmp.table]]
 name = "asf_http_service"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceIndex"
+name = "http_service_index"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.1"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceId"
+name = "http_service_id"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.2"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceCc"
+name = "http_service_cc"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.3"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceCps"
+name = "http_service_cps"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.4"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceRpsGet"
+name = "http_service_rps_get"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.5"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceRpsPost"
+name = "http_service_rps_post"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.6"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceRpsHead"
+name = "http_service_rps_head"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.7"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceRpsPut"
+name = "http_service_rps_put"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.8"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceRpsDelete"
+name = "http_service_rps_delete"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.9"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceRpsTotal"
+name = "http_service_rps_total"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.10"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyMethod"
+name = "http_service_anomaly_method"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.11"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyRequestline"
+name = "http_service_anomaly_requestline"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.12"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyHost"
+name = "http_service_anomaly_host"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.13"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyConnection"
+name = "http_service_anomaly_connection"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.14"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyContentlength"
+name = "http_service_anomaly_contentlength"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.15"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceAnomalyRange"
+name = "http_service_anomaly_range"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.16"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundInByte"
+name = "http_service_traffic_inbound_in_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.17"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundInPacket"
+name = "http_service_traffic_inbound_in_packet"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.18"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundOutByte"
+name = "http_service_traffic_inbound_out_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.19"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficInboundOutPacket"
+name = "http_service_traffic_inbound_out_packet"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.20"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundInByte"
+name = "http_service_traffic_outbound_in_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.21"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundInPacket"
+name = "http_service_traffic_outbound_in_packet"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.22"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundOutByte"
+name = "http_service_traffic_outbound_out_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.23"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceTrafficOutboundOutPacket"
+name = "http_service_traffic_outbound_out_packet"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.24"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTotal"
+name = "http_service_drop_total"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.25"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeSource"
+name = "http_service_drop_type_source"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.26"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeManBl"
+name = "http_service_drop_type_man_bl"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.27"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeDynBl"
+name = "http_service_drop_type_dyn_bl"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.28"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeAcl"
+name = "http_service_drop_type_acl"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.29"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeDdos"
+name = "http_service_drop_type_ddos"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.30"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeWaf"
+name = "http_service_drop_type_waf"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.31"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeFilter"
+name = "http_service_drop_type_filter"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.32"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeAnormaly"
+name = "http_service_drop_type_anomaly"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.33"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeParseFail"
+name = "http_service_drop_type_parse_fail"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.34"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeResource"
+name = "http_service_drop_type_resource"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.35"
 
 [[inputs.snmp.table.field]]
-name = "httpServiceDropTypeProfile"
+name = "http_service_drop_type_profile"
 oid = ".1.3.6.1.4.1.7564.33.1.2.2.1.36"
 
 [[inputs.snmp.table]]
 name = "asf_https_service"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceIndex"
+name = "https_service_index"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.1"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceId"
+name = "https_service_id"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.2"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceCc"
+name = "https_service_cc"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.3"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceCps"
+name = "https_service_cps"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.4"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceRpsGet"
+name = "https_service_rps_get"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.5"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceRpsPost"
+name = "https_service_rps_post"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.6"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceRpsHead"
+name = "https_service_rps_head"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.7"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceRpsPut"
+name = "https_service_rps_put"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.8"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceRpsDelete"
+name = "https_service_rps_delete"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.9"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceRpsTotal"
+name = "https_service_rps_total"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.10"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyMethod"
+name = "https_service_anomaly_method"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.11"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyRequestline"
+name = "https_service_anomaly_requestline"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.12"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyHost"
+name = "https_service_anomaly_host"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.13"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyConnection"
+name = "https_service_anomaly_connection"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.14"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyContentlength"
+name = "https_service_anomaly_contentlength"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.15"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceAnormalyRange"
+name = "https_service_anomaly_range"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.16"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundInByte"
+name = "https_service_traffic_inbound_in_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.17"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundInPackets"
+name = "https_service_traffic_inbound_in_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.18"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundOutByte"
+name = "https_service_traffic_inbound_out_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.19"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficInboundOutPackets"
+name = "https_service_traffic_inbound_out_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.20"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundInByte"
+name = "https_service_traffic_outbound_in_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.21"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundInPackets"
+name = "https_service_traffic_outbound_in_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.22"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundOutByte"
+name = "https_service_traffic_outbound_out_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.23"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceTrafficOutboundOutPackets"
+name = "https_service_traffic_outbound_out_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.24"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundInByte"
+name = "https_service_ssl_traffic_inbound_in_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.25"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundInPackets"
+name = "https_service_ssl_traffic_inbound_in_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.26"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundOutByte"
+name = "https_service_ssl_traffic_inbound_out_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.27"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficInboundOutPackets"
+name = "https_service_ssl_traffic_inbound_out_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.28"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundInByte"
+name = "https_service_ssl_traffic_outbound_in_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.29"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundInPackets"
+name = "https_service_ssl_traffic_outbound_in_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.30"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundOutByte"
+name = "https_service_ssl_traffic_outbound_out_byte"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.31"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslTrafficOutboundOutPackets"
+name = "https_service_ssl_traffic_outbound_out_packets"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.32"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTotal"
+name = "https_service_http_drop_total"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.33"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeSource"
+name = "https_service_http_drop_type_source"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.34"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeManBl"
+name = "https_service_http_drop_type_man_bl"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.35"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeDynBl"
+name = "https_service_http_drop_type_dyn_bl"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.36"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeAcl"
+name = "https_service_http_drop_type_acl"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.37"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeDdos"
+name = "https_service_http_drop_type_ddos"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.38"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeWaf"
+name = "https_service_http_drop_type_waf"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.39"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeFilter"
+name = "https_service_http_drop_type_filter"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.40"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeAnormaly"
+name = "https_service_http_drop_type_anomaly"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.41"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeParseFail"
+name = "https_service_http_drop_type_parse_fail"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.42"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeResource"
+name = "https_service_http_drop_type_resource"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.43"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceHttpDropTypeProfile"
+name = "https_service_http_drop_type_profile"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.44"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropTotal"
+name = "https_service_ssl_drop_total"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.45"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropResource"
+name = "https_service_ssl_drop_resource"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.46"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropDynBl"
+name = "https_service_ssl_drop_dyn_bl"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.47"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropAnormalyTotal"
+name = "https_service_ssl_drop_anomaly_total"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.48"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropMismatch"
+name = "https_service_ssl_drop_mismatch"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.49"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHandshakeVersionMismatch"
+name = "https_service_ssl_drop_handshake_version_mismatch"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.50"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropRecordVersion"
+name = "https_service_ssl_drop_record_version"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.51"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropRecordType"
+name = "https_service_ssl_drop_record_type"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.52"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHandshakeType"
+name = "https_service_ssl_drop_handshake_type"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.53"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHandshakeLen"
+name = "https_service_ssl_drop_handshake_len"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.54"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropEncryptDecrypt"
+name = "https_service_ssl_drop_encrypt_decrypt"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.55"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropHostStop"
+name = "https_service_ssl_drop_host_stop"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.56"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropSendData"
+name = "https_service_ssl_drop_send_data"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.57"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropBadCipher"
+name = "https_service_ssl_drop_bad_cipher"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.58"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropSendCard"
+name = "https_service_ssl_drop_send_card"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.59"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropNoRandom"
+name = "https_service_ssl_drop_no_random"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.60"
 
 [[inputs.snmp.table.field]]
-name = "httpsServiceSslDropBigNumberOperationFailed"
+name = "https_service_ssl_drop_big_number_operation_failed"
 oid = ".1.3.6.1.4.1.7564.33.1.3.2.1.61"
-
-
Index: /branches/amp_4_0/platform/tools/configure_telegraf_timescale.sh
===================================================================
--- /branches/amp_4_0/platform/tools/configure_telegraf_timescale.sh	(revision 2706)
+++ /branches/amp_4_0/platform/tools/configure_telegraf_timescale.sh	(working copy)
@@ -67,7 +67,7 @@
   collection_jitter = "0s"
   flush_interval = "10s"
   precision = ""
-  hostname = ""
+  hostname = "AN"
   omit_hostname = false
   skip_processors_after_aggregators = false
 
@@ -91,25 +91,75 @@
 [[inputs.diskio]]
 
 [[inputs.net]]
+  ignore_protocol_stats = true
 
 [[inputs.system]]
   fieldinclude = ["load1", "load5", "load15", "uptime"]
 
+[[processors.regex]]
+  order = 1
+  namepass = ["asf_http_service"]
+  [[processors.regex.fields]]
+    key = ".*"
+    pattern = "\\x00"
+    replacement = ""
+
 [[processors.starlark]]
-  source = """
+  order = 2
+  namepass = ["asf_http_service"]
+  source = '''
 def apply(metric):
-    # Allow scalar metrics (cpu_usage, etc.)
-    if metric.name != 'ag_virtual_site_stats' and metric.name != 'ag_vpn_stats' and metric.name != 'apv_real_stats':
-        return metric
+    for key, value in metric.fields.items():
+        if type(value) == "string" and "\x00" in value:
+            metric.fields[key] = value.replace("\x00", "")
+    if "http_service_index" not in metric.fields or metric.fields["http_service_index"] == None:
+        metric.fields["http_service_index"] = 0
+    return metric
+'''
 
-    # For table metrics, require 'serverid' or 'realServerId'
-    if 'serverid' in metric.fields or 'realServerId' in metric.fields:
-        return metric
+[[processors.starlark]]
+  order = 3
+  namepass = ["asf_http_service"]
+  source = '''
+def apply(metric):
+    if "host" in metric.fields:
+        metric.fields.pop("host")
+    if "host" in metric.tags:
+        metric.tags.pop("host")
+    if "http_service_anomaly_contentlength" in metric.fields:
+        metric.fields.pop("http_service_anomaly_contentlength")
+    return metric
+'''
 
-    # Drop only table rows missing the key field
+[[processors.starlark]]
+  order = 4
+  source = '''
+def apply(metric):
+    if metric.name == 'asf_ssl_host_statistics' and 'ssl_index' not in metric.fields:
+        return None
+    if metric.name == 'asf_syslog_history' and 'idx' not in metric.fields:
+        return None
+    if metric.name not in ['ag_virtual_site_stats', 'ag_vpn_stats', 'apv_real_stats']:
+        return metric
+    if 'real_server_id' in metric.tags or 'serverid' in metric.fields:
+        return metric
     return None
-"""
+'''
 
+[[processors.starlark]]
+  order = 5
+  namepass = ["apv_virtual_stats"]
+  source = '''
+def apply(metric):
+    total = 0
+    for key, value in metric.fields.items():
+        if (key.endswith("hits") or key.endswith("_hits")) and (type(value) == "int" or type(value) == "float"):
+            total += value
+    metric.fields["total_hits"] = total
+    return metric
+'''
+
+
 EOF
 
 # --- test config (outputs are skipped in test mode) ---
Index: /branches/amp_4_0/platform/tools/telegraf_snmp_timescale.sql
===================================================================
--- /branches/amp_4_0/platform/tools/telegraf_snmp_timescale.sql	(revision 2706)
+++ /branches/amp_4_0/platform/tools/telegraf_snmp_timescale.sql	(working copy)
@@ -85,6 +85,7 @@
     in_packet_per_sec DOUBLE PRECISION,
     out_packet_per_sec DOUBLE PRECISION,
     health_status TEXT,
+    total_hits BIGINT,
     PRIMARY KEY (time, agent_host, serverid, addr, port, protocol)
 );
 SELECT create_hypertable('apv_virtual_stats','time','agent_host', number_partitions => 8, if_not_exists => TRUE);
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/.idea/misc.xml
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/xml
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/.idea/src.iml
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/xml
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/.idea/workspace.xml
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/xml
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/djproject/urls.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/djproject/urls.py	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/djproject/urls.py	(working copy)
@@ -1,4 +1,7 @@
 from django.urls import re_path
+
+from hive.controller.apv_services_metrics import handle_get_top_apv_virtual_services_metrics, handle_get_top_apv_real_services_metrics, handle_get_top_llb_metrics
+from hive.controller.devices_metrics import handle_get_top_devices_metrics
 from hive.router import *
 from hive.session import login_handler, logout_handler, register_complete, app_login_handler, app_logout_handler
 from hive.theme import switch_theme
@@ -107,6 +110,10 @@
     re_path(r'^register_complete$', register_complete),
     re_path(r'^system-metrics-latest$', handle_get_latest_system_metrics),
     re_path(r'^system-metrics-history$', handle_get_historical_system_metrics),
+    re_path(r'^devices-metrics$', handle_get_top_devices_metrics),
+    re_path(r'^top-apv-virtual-metrics$', handle_get_top_apv_virtual_services_metrics),
+    re_path(r'^top-apv-real-metrics$', handle_get_top_apv_real_services_metrics),
+    re_path(r'^top-apv-llb-metrics$', handle_get_top_llb_metrics),
 ]
 
 handler404 = 'hive.shared.custom_404_view'
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-device-insights/dashboard-device-insights.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-device-insights/dashboard-device-insights.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-device-insights/dashboard-device-insights.ts	(working copy)
@@ -6,6 +6,7 @@
 import {DashboardInsightsApv} from '../dashboard-insights-apv/dashboard-insights-apv';
 import {DashboardInsightsSslvpn} from '../dashboard-insights-sslvpn/dashboard-insights-sslvpn';
 import {DashboardInsightsAvx} from '../dashboard-insights-avx/dashboard-insights-avx';
+import {SystemService} from '../../../services/system-service';
 
 @Component({
   selector: 'app-dashboard-device-insights',
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.html
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.html	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.html	(working copy)
@@ -12,9 +12,25 @@
                 <span class="card-title-text">Hits - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption1" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="vSHitsDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="hits">
+                <th mat-header-cell *matHeaderCellDef> Hits</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.value }}</td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="hitsColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: hitsColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="3">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -26,9 +42,25 @@
                 <span class="card-title-text">Open Connections - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption2" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="vSConnectionsDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="connections">
+                <th mat-header-cell *matHeaderCellDef> Connections</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.value }}</td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="connectionsColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: connectionsColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="3">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -40,9 +72,35 @@
                 <span class="card-title-text">Throughput - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption3" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="vSThroughputDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="inboundMbps">
+                <th mat-header-cell *matHeaderCellDef> Received (Mbps)</th>
+                <td mat-cell *matCellDef="let element">
+                  <fa-icon [icon]="['fas', 'arrow-down-long']" class="delete-icon"></fa-icon>
+                  {{ element?.inboundMbps }}
+                </td>
+              </ng-container>
+              <ng-container matColumnDef="outboundMbps">
+                <th mat-header-cell *matHeaderCellDef> Sent (Mbps)</th>
+                <td mat-cell *matCellDef="let element">
+                  <fa-icon [icon]="['fas', 'arrow-up-long']" class="success-icon"></fa-icon>
+                  {{ element?.outboundMbps }}
+                </td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="throughputColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: throughputColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="4">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -63,9 +121,25 @@
                 <span class="card-title-text">Hits - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption4" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="rSHitsDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="hits">
+                <th mat-header-cell *matHeaderCellDef> Hits</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.value }}</td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="hitsColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: hitsColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="3">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -77,9 +151,25 @@
                 <span class="card-title-text">Open Connections - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption5" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="rSConnectionsDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="connections">
+                <th mat-header-cell *matHeaderCellDef> Connections</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.value }}</td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="connectionsColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: connectionsColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="3">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -91,9 +181,35 @@
                 <span class="card-title-text">Throughput - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption6" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="rSThroughputDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="inboundMbps">
+                <th mat-header-cell *matHeaderCellDef> Received (Mbps)</th>
+                <td mat-cell *matCellDef="let element">
+                  <fa-icon [icon]="['fas', 'arrow-down-long']" class="delete-icon"></fa-icon>
+                  {{ element?.inboundMbps }}
+                </td>
+              </ng-container>
+              <ng-container matColumnDef="outboundMbps">
+                <th mat-header-cell *matHeaderCellDef> Sent (Mbps)</th>
+                <td mat-cell *matCellDef="let element">
+                  <fa-icon [icon]="['fas', 'arrow-up-long']" class="success-icon"></fa-icon>
+                  {{ element?.outboundMbps }}
+                </td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="throughputColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: throughputColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="4">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -114,9 +230,25 @@
                 <span class="card-title-text">Hits - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption7" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="llbHitsDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="hits">
+                <th mat-header-cell *matHeaderCellDef> Hits</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.value }}</td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="hitsColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: hitsColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="3">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -128,9 +260,25 @@
                 <span class="card-title-text">Open Connections - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption8" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="llbConnectionsDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="connections">
+                <th mat-header-cell *matHeaderCellDef> Connections</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.value }}</td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="connectionsColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: connectionsColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="3">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
@@ -142,9 +290,35 @@
                 <span class="card-title-text">Throughput - Top 5</span>
               </mat-card-title>
             </div>
-            <div class="chart-flex-container">
-              <div echarts [options]="chartOption9" class="chart-container"></div>
-            </div>
+            <table mat-table [dataSource]="llbThroughputDataSource" class="mat-elevation-z1 small-table">
+              <ng-container matColumnDef="serial">
+                <th mat-header-cell *matHeaderCellDef> Top</th>
+                <td mat-cell *matCellDef="let element; let i = index;"> {{ i + 1 }}</td>
+              </ng-container>
+              <ng-container matColumnDef="name">
+                <th mat-header-cell *matHeaderCellDef> Service Name</th>
+                <td mat-cell *matCellDef="let element"> {{ element?.name }}</td>
+              </ng-container>
+              <ng-container matColumnDef="inboundMbps">
+                <th mat-header-cell *matHeaderCellDef> Received (Mbps)</th>
+                <td mat-cell *matCellDef="let element">
+                  <fa-icon [icon]="['fas', 'arrow-down-long']" class="delete-icon"></fa-icon>
+                  {{ element?.inboundMbps }}
+                </td>
+              </ng-container>
+              <ng-container matColumnDef="outboundMbps">
+                <th mat-header-cell *matHeaderCellDef> Sent (Mbps)</th>
+                <td mat-cell *matCellDef="let element">
+                  <fa-icon [icon]="['fas', 'arrow-up-long']" class="success-icon"></fa-icon>
+                  {{ element?.outboundMbps }}
+                </td>
+              </ng-container>
+              <tr mat-header-row *matHeaderRowDef="throughputColumns"></tr>
+              <tr mat-row *matRowDef="let row; columns: throughputColumns;"></tr>
+              <tr class="mat-row table-no-data" *matNoDataRow>
+                <td class="mat-cell" colspan="4">No results found.</td>
+              </tr>
+            </table>
           </mat-card-content>
         </mat-card>
       </mat-grid-tile>
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.scss
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.scss	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.scss	(working copy)
@@ -160,6 +160,7 @@
   border-radius: 0;
   background-color: inherit;
   font-size: 14px !important;
+
   mat-card-header {
     color: #1170cf;
   }
@@ -175,3 +176,33 @@
 mat-card-title {
   font-size: medium;
 }
+
+:host {
+  --table-bg: transparent;
+
+  .small-table {
+    background: var(--table-bg);
+
+    .mat-row,
+    .mat-header-row,
+    [mat-row],
+    [mat-header-row] {
+      height: 36px;
+      line-height: 32px;
+      background: var(--table-bg);
+
+      &:hover {
+        background: var(--table-bg);
+      }
+    }
+
+    .mat-cell,
+    .mat-header-cell,
+    [mat-cell],
+    [mat-header-cell] {
+      padding: 4px 8px;
+      line-height: 1.2;
+      background: var(--table-bg);
+    }
+  }
+}
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-apv/dashboard-insights-apv.ts	(working copy)
@@ -5,6 +5,11 @@
 import {NgxEchartsDirective} from "ngx-echarts";
 import {SharedModule} from '../../../shared/shared-module';
 import {EChartsOption} from 'echarts';
+import {NotificationService} from '../../../services/notification';
+import {SystemService} from '../../../services/system-service';
+import {take} from 'rxjs/operators';
+import {DeviceService} from '../../../services/device-service';
+import {MatTableDataSource} from '@angular/material/table';
 
 @Component({
   selector: 'app-dashboard-insights-apv',
@@ -16,406 +21,239 @@
 })
 export class DashboardInsightsApv implements OnInit, OnChanges {
 
-  chartOption1: EChartsOption = {};
-  chartOption2: EChartsOption = {};
-  chartOption3: EChartsOption = {};
-  chartOption4: EChartsOption = {};
-  chartOption5: EChartsOption = {};
-  chartOption6: EChartsOption = {};
-  chartOption7: EChartsOption = {};
-  chartOption8: EChartsOption = {};
-  chartOption9: EChartsOption = {};
+  hitsColumns: string[] = ['serial', 'name', 'hits'];
+  connectionsColumns: string[] = ['serial', 'name', 'connections'];
+  throughputColumns: string[] = ['serial', 'name', 'inboundMbps', 'outboundMbps'];
 
+  vSHitsDataSource: MatTableDataSource<any> = new MatTableDataSource();
+  vSConnectionsDataSource: MatTableDataSource<any> = new MatTableDataSource();
+  vSThroughputDataSource: MatTableDataSource<any> = new MatTableDataSource();
+
+  rSHitsDataSource: MatTableDataSource<any> = new MatTableDataSource();
+  rSConnectionsDataSource: MatTableDataSource<any> = new MatTableDataSource();
+  rSThroughputDataSource: MatTableDataSource<any> = new MatTableDataSource();
+
+  llbHitsDataSource: MatTableDataSource<any> = new MatTableDataSource();
+  llbConnectionsDataSource: MatTableDataSource<any> = new MatTableDataSource();
+  llbThroughputDataSource: MatTableDataSource<any> = new MatTableDataSource();
+
+  constructor(
+    private _notification: NotificationService,
+    private _system: SystemService,
+    private _device: DeviceService,
+  ) {
+  }
+
   ngOnInit(): void {
-    this.updateChartOption();
+    setTimeout(() => {
+      this.getDeviceGroups();
+    })
   }
 
   ngOnChanges(changes: SimpleChanges): void {
     if (changes['cpuUsagePercentage']) {
-      this.updateChartOption();
     }
   }
 
-  private updateChartOption() {
-    let _vdata: any = {
-      hits: [
-        {name: 'vs1', value: 60},
-        {name: 'vs2', value: 50},
-        {name: 'vs3', value: 44},
-        {name: 'vs4', value: 40},
-        {name: 'vs5', value: 35}
-      ],
-      connections: [
-        {name: 'vs1', value: 40},
-        {name: 'vs2', value: 50},
-        {name: 'vs3', value: 64},
-        {name: 'vs4', value: 40},
-        {name: 'vs5', value: 35}
-      ],
-      throughput: [
-        {name: 'vs1', inbound: 10, outbound: 20},
-        {name: 'vs2', inbound: 20, outbound: 5},
-        {name: 'vs3', inbound: 10, outbound: 8},
-        {name: 'vs4', inbound: 7, outbound: 12},
-        {name: 'vs5', inbound: 8, outbound: 11},
-      ]
-    }
-    let _rdata: any = {
-      hits: [
-        {name: 'rs1', value: 60},
-        {name: 'rs2', value: 50},
-        {name: 'rs3', value: 44},
-        {name: 'rs4', value: 40},
-        {name: 'rs5', value: 35}
-      ],
-      connections: [
-        {name: 'rs1', value: 40},
-        {name: 'rs2', value: 50},
-        {name: 'rs3', value: 64},
-        {name: 'rs4', value: 40},
-        {name: 'rs5', value: 35}
-      ],
-      throughput: [
-        {name: 'rs1', inbound: 10, outbound: 20},
-        {name: 'rs2', inbound: 20, outbound: 5},
-        {name: 'rs3', inbound: 10, outbound: 8},
-        {name: 'rs4', inbound: 7, outbound: 12},
-        {name: 'rs5', inbound: 8, outbound: 11},
-      ]
-    }
-    let _ldata: any = {
-      hits: [
-        {name: 'llb1', value: 60},
-        {name: 'llb2', value: 50},
-        {name: 'llb3', value: 44},
-        {name: 'llb4', value: 40},
-        {name: 'llb5', value: 35}
-      ],
-      connections: [
-        {name: 'llb1', value: 40},
-        {name: 'llb2', value: 50},
-        {name: 'llb3', value: 64},
-        {name: 'llb4', value: 40},
-        {name: 'llb5', value: 35}
-      ],
-      throughput: [
-        {name: 'llb1', inbound: 10, outbound: 20},
-        {name: 'llb2', inbound: 20, outbound: 5},
-        {name: 'llb3', inbound: 10, outbound: 8},
-        {name: 'llb4', inbound: 7, outbound: 12},
-        {name: 'llb5', inbound: 8, outbound: 11},
-      ]
-    }
-    _rdata?.hits.sort((a: any, b: any) => b.value - a.value);
-    _rdata?.connections.sort((a: any, b: any) => b.value - a.value);
-    _rdata?.throughput.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
-    const sortedRNames = _rdata?.throughput.map((item: any) => item.name);
-    const sortedRInbound = _rdata?.throughput.map((item: any) => item.inbound);
-    const sortedROutbound = _rdata?.throughput.map((item: any) => item.outbound);
+  devices: any[] = [];
+  groups: any[] = [];
 
-    _vdata?.hits.sort((a: any, b: any) => b.value - a.value);
-    _vdata?.connections.sort((a: any, b: any) => b.value - a.value);
-    _vdata?.throughput.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
-    const sortedVNames = _vdata?.throughput.map((item: any) => item.name);
-    const sortedVInbound = _vdata?.throughput.map((item: any) => item.inbound);
-    const sortedVOutbound = _vdata?.throughput.map((item: any) => item.outbound);
+  getDeviceGroups(): void {
+    this.devices = [];
+    this.groups = [];
+    // ToDo: Update with actual RoleId with RBAC
+    let roleId = "0"
+    let rawPayload = new FormData();
+    rawPayload.set('action', 'FilterRoleDeviceGroups');
+    rawPayload.set('options', JSON.stringify({"role_id": roleId}));
+    this._device.getDeviceGroups(rawPayload)
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          if (result && result.length > 1) {
+            if (result[1] && 'result' in result[1]) {
+              let groups = result[1].result;
+              groups.forEach((group: any) => {
+                this.groups.push(group?.group_name);
+                group?.device_list.forEach((device: any) => {
+                  this.devices.push(device);
+                })
+              })
+              this.getTopAPVVirtualServicesMetrics();
+              this.getTopAPVRealServicesMetrics();
+              this.getTopAPVLLBMetrics();
+            }
+          }
+        }, error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
+        }
+      })
+  }
 
-    _ldata?.hits.sort((a: any, b: any) => b.value - a.value);
-    _ldata?.connections.sort((a: any, b: any) => b.value - a.value);
-    _ldata?.throughput.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
-    const sortedLNames = _ldata?.throughput.map((item: any) => item.name);
-    const sortedLInbound = _ldata?.throughput.map((item: any) => item.inbound);
-    const sortedLOutbound = _ldata?.throughput.map((item: any) => item.outbound);
+  virtualServiceMetrics: any = [];
 
-    this.chartOption1 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
+  getTopAPVVirtualServicesMetrics() {
+    let payload = {}
+    this._system.getTopAPVVirtualServicesMetrics(payload)
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          this.devices.forEach((_device: any) => {
+            result.forEach((_metric: any) => {
+              if (_metric?.agent_host === _device?.ip) {
+                _metric.device_name = _device?.name;
+                _metric.device_type = _device?.type;
+              }
+            })
+          })
+          this.virtualServiceMetrics = result;
+          this.updateVirtualServicesMetricsCharts();
+        },
+        error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
         }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01],
-        max: 100
-      },
-      yAxis: {
-        type: 'category',
-        data: _vdata?.hits.map((item: any) => item?.name),
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Hits',
-          type: 'bar',
-          data: _vdata?.hits.map((item: any) => item?.value)
-        }
-      ]
-    };
+      });
+  }
 
-    this.chartOption2 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01],
-        max: 100
-      },
-      yAxis: {
-        type: 'category',
-        data: _vdata?.connections.map((item: any) => item?.name),
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Connections',
-          type: 'bar',
-          data: _vdata?.connections.map((item: any) => item?.value)
-        }
-      ]
-    };
+  realServiceMetrics: any = [];
 
-    this.chartOption3 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      legend: {
-        bottom: 'bottom'
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01]
-      },
-      yAxis: {
-        type: 'category',
-        data: sortedVNames,
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Inbound',
-          type: 'bar',
-          data: sortedVInbound
+  getTopAPVRealServicesMetrics() {
+    let payload = {}
+    this._system.getTopAPVRealServicesMetrics(payload)
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          this.devices.forEach((_device: any) => {
+            result.forEach((_metric: any) => {
+              if (_metric?.agent_host === _device?.ip) {
+                _metric.device_name = _device?.name;
+                _metric.device_type = _device?.type;
+              }
+            })
+          })
+          this.realServiceMetrics = result;
+          this.updateRealServicesMetricsCharts();
         },
-        {
-          name: 'Outbound',
-          type: 'bar',
-          data: sortedVOutbound
+        error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
         }
-      ]
-    };
+      });
+  }
 
-    this.chartOption4 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01],
-        max: 100
-      },
-      yAxis: {
-        type: 'category',
-        data: _rdata?.hits.map((item: any) => item?.name),
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Hits',
-          type: 'bar',
-          data: _rdata?.hits.map((item: any) => item?.value)
-        }
-      ]
-    };
+  llbMetrics: any = [];
 
-    this.chartOption5 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01],
-        max: 100
-      },
-      yAxis: {
-        type: 'category',
-        data: _rdata?.connections.map((item: any) => item?.name),
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Connections',
-          type: 'bar',
-          data: _rdata?.connections.map((item: any) => item?.value)
-        }
-      ]
-    };
-
-    this.chartOption6 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      legend: {
-        bottom: 'bottom'
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01]
-      },
-      yAxis: {
-        type: 'category',
-        data: sortedRNames,
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Inbound',
-          type: 'bar',
-          data: sortedRInbound
+  getTopAPVLLBMetrics() {
+    let payload = {}
+    this._system.getTopAPVLLBMetrics(payload)
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          this.devices.forEach((_device: any) => {
+            result.forEach((_metric: any) => {
+              if (_metric?.agent_host === _device?.ip) {
+                _metric.device_name = _device?.name;
+                _metric.device_type = _device?.type;
+              }
+            })
+          })
+          this.llbMetrics = result;
+          this.updateLLBMetricsCharts();
         },
-        {
-          name: 'Outbound',
-          type: 'bar',
-          data: sortedROutbound
+        error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
         }
-      ]
-    };
+      });
+  }
 
-    this.chartOption7 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01],
-        max: 100
-      },
-      yAxis: {
-        type: 'category',
-        data: _ldata?.hits.map((item: any) => item?.name),
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Hits',
-          type: 'bar',
-          data: _ldata?.hits.map((item: any) => item?.value)
-        }
-      ]
-    };
+  convertData(rawData: any): any {
+    const connections = rawData
+      .filter((item: any) => item.metric === 'connections')
+      .map((item: any) => ({name: `${item.service_name} (${item.device_name})`, value: item.value}));
 
-    this.chartOption8 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01],
-        max: 100
-      },
-      yAxis: {
-        type: 'category',
-        data: _ldata?.connections.map((item: any) => item?.name),
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Connections',
-          type: 'bar',
-          data: _ldata?.connections.map((item: any) => item?.value)
-        }
-      ]
-    };
+    const hits = rawData
+      .filter((item: any) => item.metric === 'hits' || item.metric === 'requests')
+      .map((item: any) => ({name: `${item.service_name} (${item.device_name})`, value: item.value}));
 
-    this.chartOption9 = {
-      tooltip: {
-        trigger: 'axis',
-        axisPointer: {
-          type: 'shadow'
-        }
-      },
-      grid: {
-        left: '3%',
-        containLabel: true
-      },
-      legend: {
-        bottom: 'bottom'
-      },
-      xAxis: {
-        type: 'value',
-        boundaryGap: [0, 0.01]
-      },
-      yAxis: {
-        type: 'category',
-        data: sortedLNames,
-        inverse: true
-      },
-      series: [
-        {
-          name: 'Inbound',
-          type: 'bar',
-          data: sortedLInbound
-        },
-        {
-          name: 'Outbound',
-          type: 'bar',
-          data: sortedLOutbound
-        }
-      ]
+    const network = rawData
+      .filter((item: any) => item.metric === 'network')
+      .map((item: any) => ({
+        name: `${item.service_name} (${item.device_name})`,
+        inbound: item.received / (1024 * 1024),
+        outbound: item.sent / (1024 * 1024),
+      }));
+
+    return {
+      connections: connections,
+      hits: hits,
+      network: network,
     };
   }
+
+  private updateVirtualServicesMetricsCharts(): void {
+    let _data: any = this.convertData(this.virtualServiceMetrics);
+
+    _data?.connections.sort((a: any, b: any) => b.value - a.value);
+    this.vSConnectionsDataSource.data = _data?.connections
+    _data?.hits.sort((a: any, b: any) => b.value - a.value);
+    this.vSHitsDataSource.data = _data?.hits
+
+    _data?.network.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
+    const sortedNames = _data?.network.map((item: any) => item.name);
+    const sortedInbound = _data?.network.map((item: any) => item.inbound);
+    const sortedOutbound = _data?.network.map((item: any) => item.outbound);
+
+    this.vSThroughputDataSource.data = sortedNames.map((name: any, index: any) => {
+      return {
+        name: name,
+        inboundMbps: sortedInbound[index],
+        outboundMbps: sortedOutbound[index]
+      };
+    });
+  }
+
+  private updateRealServicesMetricsCharts(): void {
+    let _data: any = this.convertData(this.realServiceMetrics);
+
+    _data?.connections.sort((a: any, b: any) => b.value - a.value);
+    this.rSConnectionsDataSource.data = _data?.connections
+    _data?.hits.sort((a: any, b: any) => b.value - a.value);
+    this.rSHitsDataSource.data = _data?.hits
+    _data?.network.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
+    const sortedNames = _data?.network.map((item: any) => item.name);
+    const sortedInbound = _data?.network.map((item: any) => item.inbound);
+    const sortedOutbound = _data?.network.map((item: any) => item.outbound);
+
+    this.rSThroughputDataSource.data = sortedNames.map((name: any, index: any) => {
+      return {
+        name: name,
+        inboundMbps: sortedInbound[index],
+        outboundMbps: sortedOutbound[index]
+      };
+    });
+  }
+
+  private updateLLBMetricsCharts(): void {
+    let _data: any = this.convertData(this.llbMetrics);
+
+    _data?.connections.sort((a: any, b: any) => b.value - a.value);
+    this.llbConnectionsDataSource.data = _data?.connections
+    _data?.hits.sort((a: any, b: any) => b.value - a.value);
+    this.llbHitsDataSource.data = _data?.hits
+    _data?.network.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
+    const sortedNames = _data?.network.map((item: any) => item.name);
+    const sortedInbound = _data?.network.map((item: any) => item.inbound);
+    const sortedOutbound = _data?.network.map((item: any) => item.outbound);
+
+    this.llbThroughputDataSource.data = sortedNames.map((name: any, index: any) => {
+      return {
+        name: name,
+        inboundMbps: sortedInbound[index],
+        outboundMbps: sortedOutbound[index]
+      };
+    });
+  }
 }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-devices/dashboard-insights-devices.html
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-devices/dashboard-insights-devices.html	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-devices/dashboard-insights-devices.html	(working copy)
@@ -8,7 +8,7 @@
           </mat-card-title>
         </div>
         <div class="chart-flex-container">
-          <div echarts [options]="chartOption1" class="chart-container"></div>
+          <div echarts [options]="devicesCPUChartOption1" class="chart-container"></div>
         </div>
       </mat-card-content>
     </mat-card>
@@ -22,7 +22,7 @@
           </mat-card-title>
         </div>
         <div class="chart-flex-container">
-          <div echarts [options]="chartOption2" class="chart-container"></div>
+          <div echarts [options]="devicesMemoryChartOption1" class="chart-container"></div>
         </div>
       </mat-card-content>
     </mat-card>
@@ -36,7 +36,7 @@
           </mat-card-title>
         </div>
         <div class="chart-flex-container">
-          <div echarts [options]="chartOption3" class="chart-container"></div>
+          <div echarts [options]="devicesThroughputChartOption1" class="chart-container"></div>
         </div>
       </mat-card-content>
     </mat-card>
@@ -46,11 +46,12 @@
       <mat-card-content class="card-content-wrapper">
         <div class="card-header-row">
           <mat-card-title class="card-title">
-            <span class="card-title-text">Connection Status</span>
+            <span class="card-title-text">Connection Status ({{ deviceStats?.total?.connected }}
+              /{{ deviceStats?.total?.connected + deviceStats?.total?.disconnected }})</span>
           </mat-card-title>
         </div>
         <div class="chart-flex-container">
-          <div echarts [options]="chartOption4" class="chart-container"></div>
+          <div echarts [options]="connectionChartOption1" class="chart-container"></div>
         </div>
       </mat-card-content>
     </mat-card>
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-devices/dashboard-insights-devices.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-devices/dashboard-insights-devices.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-insights-devices/dashboard-insights-devices.ts	(working copy)
@@ -1,7 +1,21 @@
 import {Component, OnChanges, OnInit, SimpleChanges} from '@angular/core';
 import {EChartsOption} from 'echarts';
 import {SharedModule} from '../../../shared/shared-module';
+import {take} from 'rxjs/operators';
+import {DeviceService} from '../../../services/device-service';
+import {SystemService} from '../../../services/system-service';
+import {NotificationService} from '../../../services/notification';
 
+export interface DeviceTypeStatus {
+  connected: number;
+  disconnected: number;
+}
+
+export interface DeviceGraphData {
+  total: DeviceTypeStatus;
+  types: Map<string, DeviceTypeStatus>;
+}
+
 @Component({
   selector: 'app-dashboard-insights-devices',
   imports: [
@@ -12,13 +26,21 @@
 })
 export class DashboardInsightsDevices implements OnInit, OnChanges {
 
-  chartOption1: EChartsOption = {};
-  chartOption2: EChartsOption = {};
-  chartOption3: EChartsOption = {};
-  chartOption4: EChartsOption = {};
+  devicesCPUChartOption1: EChartsOption = {};
+  devicesMemoryChartOption1: EChartsOption = {};
+  devicesThroughputChartOption1: EChartsOption = {};
+  connectionChartOption1: EChartsOption = {};
 
+  constructor(
+    private _device: DeviceService,
+    private _system: SystemService,
+    private _notification: NotificationService,
+  ) {
+  }
   ngOnInit(): void {
-    this.updateChartOption();
+    setTimeout(() => {
+      this.getDeviceGroups();
+    })
   }
 
   ngOnChanges(changes: SimpleChanges): void {
@@ -27,30 +49,145 @@
     }
   }
 
-  private updateChartOption() {
-    let _data: any = {
-      cpu: [
-        {name: 'APV1', value: 60},
-        {name: 'vAPV3', value: 50},
-        {name: 'vAPV2', value: 44},
-        {name: 'vASF1', value: 40},
-        {name: 'vxAG2', value: 35}
-      ],
-      memory: [
-        {name: 'APV1', value: 40},
-        {name: 'vAPV3', value: 50},
-        {name: 'vAPV2', value: 64},
-        {name: 'vASF1', value: 40},
-        {name: 'vxAG2', value: 35}
-      ],
-      throughput: [
-        {name: 'APV1', inbound: 10, outbound: 20},
-        {name: 'vASF1', inbound: 20, outbound: 5},
-        {name: 'vxAG2', inbound: 10, outbound: 8},
-        {name: 'vAPV3', inbound: 7, outbound: 12},
-        {name: 'vAPV2', inbound: 8, outbound: 11},
-      ]
+  devices: any[] = [];
+  groups: any[] = [];
+  deviceStats: any = {}
+  deviceConnectionStats: any = {}
+  connectedDevices: number = 0;
+
+  getDeviceGroups(): void {
+    this.devices = [];
+    this.groups = [];
+    // ToDo: Update with actual RoleId with RBAC
+    let roleId = "0"
+    let rawPayload = new FormData();
+    rawPayload.set('action', 'FilterRoleDeviceGroups');
+    rawPayload.set('options', JSON.stringify({"role_id": roleId}));
+    this._device.getDeviceGroups(rawPayload)
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          if (result && result.length > 1) {
+            if (result[1] && 'result' in result[1]) {
+              let groups = result[1].result;
+              groups.forEach((group: any) => {
+                this.groups.push(group?.group_name);
+                group?.device_list.forEach((device: any) => {
+                  this.devices.push(device);
+                })
+              })
+              this.deviceStats =  this.getDeviceGraphData(this.devices);
+              this.deviceConnectionStats = this.transformChartData(this.deviceStats.types.entries());
+              this.connectedDevices = this.devices.filter((device: any) => device?.connection === true).length;
+              this.getConnectedDevicesMetrics();
+            }
+          }
+          this.updateChartOption();
+        }, error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
+        }
+      })
+  }
+
+  connectedDevicesMetrics: any = [];
+
+  getConnectedDevicesMetrics() {
+    let payload = {}
+    this._system.getConnectedDevicesMetrics(payload)
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          this.devices.forEach((_device: any) => {
+            result.forEach((_metric: any) => {
+              if (_metric?.agent_host === _device?.ip) {
+                _metric.device_name = _device?.name;
+                _metric.device_type = _device?.type;
+              }
+            })
+          })
+          this.connectedDevicesMetrics = result;
+          this.updateDeviceMetricsCharts();
+        },
+        error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
+        }
+      });
+  }
+
+  transformChartData(deviceData: [string, { connected: number, disconnected: number }][]) {
+    const yAxisData: string[] = [];
+    const connectedData: number[] = [];
+    const disconnectedData: number[] = [];
+
+    deviceData.forEach(([type, status]) => {
+      yAxisData.push(type);
+      connectedData.push(status.connected);
+      disconnectedData.push(status.disconnected);
+    });
+
+    return { yAxisData, connectedData, disconnectedData };
+  }
+
+  getDeviceGraphData(devices: any): DeviceGraphData {
+    const totalStatus: DeviceTypeStatus = { connected: 0, disconnected: 0 };
+    const typesStatus = new Map<string, DeviceTypeStatus>();
+
+    if (!devices || devices.length === 0) {
+      return { total: totalStatus, types: typesStatus };
     }
+
+    devices.forEach((device: any) => {
+      // Update the total counts
+      if (device.connection) {
+        totalStatus.connected++;
+      } else {
+        totalStatus.disconnected++;
+      }
+
+      // Update the per-type counts
+      if (!typesStatus.has(device.type)) {
+        typesStatus.set(device.type, { connected: 0, disconnected: 0 });
+      }
+      const status = typesStatus.get(device.type)!;
+      if (device.connection) {
+        status.connected++;
+      } else {
+        status.disconnected++;
+      }
+    });
+
+    return { total: totalStatus, types: typesStatus };
+  }
+
+  convertData(): any {
+    const cpuData = this.connectedDevicesMetrics
+      .filter((item: any) => item.metric === 'cpu')
+      .map((item: any) => ({ name: item.device_name, value: item.value }));
+
+    const memoryData = this.connectedDevicesMetrics
+      .filter((item: any) => item.metric === 'memory')
+      .map((item: any) => ({ name: item.device_name, value: item.value }));
+
+    const throughputData = this.connectedDevicesMetrics
+      .filter((item: any) => item.metric === 'network')
+      .map((item: any) => ({
+        name: item.device_name,
+        inbound: item.total_in / (1024 * 1024),
+        outbound: item.total_out / (1024 * 1024),
+      }));
+
+    return {
+      cpu: cpuData,
+      memory: memoryData,
+      throughput: throughputData,
+    };
+  }
+
+  private updateDeviceMetricsCharts(): void {
+    let _data: any = this.convertData();
+
     _data?.cpu.sort((a: any, b: any) => b.value - a.value);
     _data?.memory.sort((a: any, b: any) => b.value - a.value);
     _data?.throughput.sort((a: any, b: any) => (b.inbound + b.outbound) - (a.inbound + a.outbound));
@@ -58,7 +195,7 @@
     const sortedInbound = _data?.throughput.map((item: any) => item.inbound);
     const sortedOutbound = _data?.throughput.map((item: any) => item.outbound);
 
-    this.chartOption1 = {
+    this.devicesCPUChartOption1 = {
       tooltip: {
         trigger: 'axis',
         axisPointer: {
@@ -69,15 +206,21 @@
         left: '3%',
         containLabel: true
       },
-      xAxis: {
+      yAxis: {
         type: 'value',
         boundaryGap: [0, 0.01],
-        max: 100
+        max: 100,
+        name: '%',
+        nameLocation: 'end',
+        nameGap: 20,
+        axisLabel: {
+          formatter: '{value}'
+        }
       },
-      yAxis: {
+      xAxis: {
         type: 'category',
         data: _data?.cpu.map((item: any) => item?.name),
-        inverse: true
+        inverse: false
       },
       series: [
         {
@@ -88,7 +231,7 @@
       ]
     };
 
-    this.chartOption2 = {
+    this.devicesMemoryChartOption1 = {
       tooltip: {
         trigger: 'axis',
         axisPointer: {
@@ -99,15 +242,21 @@
         left: '3%',
         containLabel: true
       },
-      xAxis: {
+      yAxis: {
         type: 'value',
         boundaryGap: [0, 0.01],
-        max: 100
+        max: 100,
+        name: '%',
+        nameLocation: 'end',
+        nameGap: 20,
+        axisLabel: {
+          formatter: '{value}'
+        }
       },
-      yAxis: {
+      xAxis: {
         type: 'category',
         data: _data?.memory.map((item: any) => item?.name),
-        inverse: true
+        inverse: false
       },
       series: [
         {
@@ -118,25 +267,38 @@
       ]
     };
 
-    this.chartOption3 = {
+    this.devicesThroughputChartOption1 = {
       tooltip: {
         trigger: 'axis',
         axisPointer: {
           type: 'shadow'
+        },
+        formatter: (params: any) => {
+          let tooltipContent = `${params[0].name}<br/>`;
+          params.forEach((param: any) => {
+            const valueInMbps = param.value.toFixed(2);
+            tooltipContent += `${param.marker} ${param.seriesName}: ${valueInMbps} Mbps<br/>`;
+          });
+          return tooltipContent;
         }
       },
       grid: {
         left: '3%',
         containLabel: true
       },
-      xAxis: {
+      yAxis: {
         type: 'value',
-        boundaryGap: [0, 0.01]
+        boundaryGap: [0, 0.01],
+        name: 'Mbps',
+        nameLocation: 'end',
+        nameGap: 20,
+        axisLabel: {
+          formatter: '{value}'
+        }
       },
-      yAxis: {
+      xAxis: {
         type: 'category',
         data: sortedNames,
-        inverse: true
       },
       series: [
         {
@@ -151,34 +313,63 @@
         }
       ]
     };
+  }
 
-    this.chartOption4 = {
+  private updateChartOption() {
+
+    this.connectionChartOption1 = {
       tooltip: {
-        trigger: 'item'
+        trigger: 'axis',
+        axisPointer: {
+          type: 'shadow'
+        }
       },
       legend: {
-        top: '5%',
-        left: 'center'
+        bottom: 'bottom'
       },
+      yAxis: {
+        type: 'value',
+        axisLabel: {
+          formatter: function (value: number) {
+            if (value % 1 === 0) {
+              return String(value);
+            }
+            return '';
+          },
+        },
+      },
+      xAxis: {
+        type: 'category',
+        data: this.deviceConnectionStats?.yAxisData
+      },
       series: [
         {
-          name: 'Devices Status',
-          type: 'pie',
-          radius: ['40%', '70%'],
-          avoidLabelOverlap: false,
+          name: 'Connected',
+          type: 'bar',
+          stack: 'total',
+          color: 'green',
           label: {
-            show: false,
-            position: 'bottom'
+            show: true
           },
-          labelLine: {
-            show: false
+          emphasis: {
+            focus: 'series'
           },
-          data: [
-            {value: 10, name: 'Connected', itemStyle: {color: '#4CAF50'}},
-            {value: 1, name: 'Disconnected', itemStyle: {color: '#F44336'}}
-          ]
+          data: this.deviceConnectionStats?.connectedData
+        },
+        {
+          name: 'Disconnected',
+          type: 'bar',
+          stack: 'total',
+          label: {
+            show: true
+          },
+          color: 'red',
+          emphasis: {
+            focus: 'series'
+          },
+          data: this.deviceConnectionStats?.disconnectedData
         }
       ]
-    }
+    };
   }
 }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.html
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.html	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.html	(working copy)
@@ -6,11 +6,11 @@
           <mat-card-title class="card-title">Devices</mat-card-title>
         </div>
         <div class="metric-value">
-          <span class="online-count">{{connectedDevices}}</span>
-          <span class="total-count">/{{devices.length}}</span>
+          <span class="online-count">{{ connectedDevices }}</span>
+          <span class="total-count">/{{ devices.length }}</span>
         </div>
         @if (devices.length - connectedDevices > 0) {
-          <p class="status-details">{{devices.length - connectedDevices}} device(s) offline</p>
+          <p class="status-details">{{ devices.length - connectedDevices }} device(s) offline</p>
         } @else {
           <p class="success-icon align-center">All devices are online.</p>
         }
@@ -24,7 +24,7 @@
           <mat-card-title class="card-title">Services</mat-card-title>
         </div>
         <div class="metric-value">
-          <span class="online-count">-1</span>
+          <span class="online-count">{{virtualServices.length}}</span>
           <span class="total-count"></span>
         </div>
         <p class="status-details active">Active Services</p>
@@ -69,9 +69,14 @@
                      (click)="enlargeSystemLoad()"></fa-icon>
           </mat-card-title>
         </div>
-        <div class="chart-flex-container">
-          <div echarts [options]="chartOption1" class="chart-container"></div>
-          <div echarts [options]="chartOption2" class="chart-container"></div>
+        <div class="main-chart-layout">
+          <div class="chart-column first-column">
+            <div echarts [options]="systemLoadChartOption1" class="chart-container"></div>
+          </div>
+          <div class="chart-column second-column chart-stack-container">
+            <div echarts [options]="systemLoadChartOption2" class="chart-container"></div>
+            <div echarts [options]="systemLoadChartOption3" class="chart-container"></div>
+          </div>
         </div>
       </mat-card-content>
     </mat-card>
@@ -87,14 +92,19 @@
           </mat-card-title>
         </div>
         <div class="card-body-content">
-          <div class="metrics-horizontal-container">
-            <div class="metric-item">
-              <span class="metric-value">{{networkMetrics?.bytes_sent_bps | bytes}}</span>
-              <span class="metric-label">Outbound</span>
+          <div class="main-chart-layout">
+            <div class="chart-column first-column-1">
+              <div echarts [options]="networkThroughputChartOption1" class="chart-container"></div>
             </div>
-            <div class="metric-item">
-              <span class="metric-value">{{networkMetrics?.bytes_recv_bps | bytes}}</span>
-              <span class="metric-label">Inbound</span>
+            <div class="chart-column second-column-1 chart-stack-container">
+              <div class="metric-item">
+                <span class="metric-value">{{ networkMetrics?.bytes_sent_bps | bytes }}</span>
+                <span class="metric-label">Sent</span>
+              </div>
+              <div class="metric-item">
+                <span class="metric-value">{{ networkMetrics?.bytes_recv_bps | bytes }}</span>
+                <span class="metric-label">Received</span>
+              </div>
             </div>
           </div>
         </div>
@@ -107,32 +117,22 @@
         <div class="card-header-row">
           <mat-card-title class="card-title">
             <span class="card-title-text">Disk Usage</span>
-            <fa-icon [icon]="['fas', 'expand']" class="fa-1x a-link" matTooltip="Expand"
-                     (click)="enlargeSystemDiskUsage()"></fa-icon>
           </mat-card-title>
         </div>
-        <div class="chart-flex-container">
-          <div echarts [options]="chartOption3" class="chart-container"></div>
-          <div echarts [options]="chartOption4" class="chart-container"></div>
-        </div>
-        <div class="chart-flex-container">
-          <div class="metrics-horizontal-container">
+        <div class="main-chart-layout">
+          <div class="chart-column first-column">
+            <div echarts [options]="diskIOChartOption1" class="chart-container"></div>
+          </div>
+          <div class="chart-column second-column chart-stack-container">
+            <div echarts [options]="diskChartOption1" class="chart-container"></div>
             <div class="metric-item">
-              <span class="metric-value">{{diskMetrics?.used_bytes | bytes}}</span>
+              <span class="metric-value">{{ diskMetrics?.used_bytes | bytes }}</span>
               <span class="metric-label">Used</span>
             </div>
             <div class="metric-item">
-              <span class="metric-value">{{diskMetrics?.free_bytes | bytes}}</span>
+              <span class="metric-value">{{ diskMetrics?.free_bytes | bytes }}</span>
               <span class="metric-label">Free</span>
             </div>
-            <div class="metric-item">
-              <span class="metric-value">{{currentSystemMetrics?.diskio?.read_speed | bytes}}</span>
-              <span class="metric-label">Read Rate</span>
-            </div>
-            <div class="metric-item">
-              <span class="metric-value">{{currentSystemMetrics?.diskio?.write_speed | bytes}}</span>
-              <span class="metric-label">Write Rate</span>
-            </div>
           </div>
         </div>
       </mat-card-content>
@@ -144,12 +144,11 @@
         <div class="card-header-row">
           <mat-card-title class="card-title">
             <span class="card-title-text">Devices</span>
-            <fa-icon [icon]="['fas', 'expand']" class="fa-1x a-link" matTooltip="Expand"
-                     (click)="enlargeSystemDevices()"></fa-icon>
           </mat-card-title>
         </div>
         <div class="chart-flex-container">
-          <div echarts [options]="chartOption5" class="chart-container"></div>
+          <div echarts [options]="connectionChartOption1" class="chart-container"></div>
+          <div echarts [options]="connectionChartOption2" class="chart-container"></div>
         </div>
       </mat-card-content>
     </mat-card>
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.scss
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.scss	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.scss	(working copy)
@@ -147,9 +147,35 @@
   color: #333;
 }
 
-//.metric-label {
-//  font-size: 0.9rem;
-//  color: #777;
-//  text-transform: uppercase;
-//  margin-top: 5px;
-//}
+.main-chart-layout {
+  display: flex;
+  height: 100%;
+  width: 100%;
+}
+
+.first-column {
+  flex: 0 0 70%;
+}
+
+.second-column {
+  flex: 0 0 30%;
+}
+
+.first-column-1 {
+  flex: 0 0 82%;
+}
+
+.second-column-1 {
+  flex: 0 0 18%;
+}
+
+.chart-container {
+  width: 100%;
+  height: 100%;
+}
+
+.chart-stack-container {
+  display: flex;
+  flex-direction: column;
+  gap: 10px;
+}
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/dashboard-system-insights.ts	(working copy)
@@ -3,7 +3,6 @@
 import {EChartsOption} from 'echarts';
 import {MAT_DIALOG_DATA, MatDialog, MatDialogConfig, MatDialogRef} from '@angular/material/dialog';
 import {take} from 'rxjs/operators';
-import {MatTableDataSource} from '@angular/material/table';
 import {DeviceService} from '../../../services/device-service';
 import {NotificationService} from '../../../services/notification';
 import {SystemService} from '../../../services/system-service';
@@ -18,6 +17,7 @@
   total: DeviceTypeStatus;
   types: Map<string, DeviceTypeStatus>;
 }
+
 @Component({
   selector: 'app-dashboard-system-insights',
   imports: [SharedModule, BytesPipe],
@@ -26,12 +26,18 @@
 })
 export class DashboardSystemInsights implements OnInit, OnChanges {
 
-  chartOption1: EChartsOption = {};
-  chartOption2: EChartsOption = {};
-  chartOption3: EChartsOption = {};
-  chartOption4: EChartsOption = {};
-  chartOption5: EChartsOption = {};
+  systemLoadChartOption1: EChartsOption = {};
+  systemLoadChartOption2: EChartsOption = {};
+  systemLoadChartOption3: EChartsOption = {};
 
+  networkThroughputChartOption1: EChartsOption = {};
+
+  diskIOChartOption1: EChartsOption = {};
+  diskChartOption1: EChartsOption = {};
+
+  connectionChartOption1: EChartsOption = {};
+  connectionChartOption2: EChartsOption = {};
+
   constructor(
     private _device: DeviceService,
     private _system: SystemService,
@@ -40,8 +46,11 @@
   }
 
   ngOnInit(): void {
-    this.getDeviceGroups();
-    this.getLatestSystemMetrics();
+    setTimeout(() => {
+      this.getDeviceGroups();
+      this.getLatestSystemMetrics();
+      this.getHistoricalSystemMetrics();
+    })
   }
 
   devices: any[] = [];
@@ -72,11 +81,37 @@
       });
   }
 
+  historicalCPUMetrics: any = {};
+  historicalMemoryMetrics: any = {};
+  historicalNetworkMetrics: any = {};
+  historicalDiskIOMetrics: any = {};
+
+  getHistoricalSystemMetrics() {
+    this._system.getHistoricalSystemMetrics()
+      .pipe(take(1))
+      .subscribe({
+        next: (result: any) => {
+          this.historicalCPUMetrics = result?.cpu_history;
+          this.historicalMemoryMetrics = result?.mem_history;
+          this.historicalNetworkMetrics = result?.net_history;
+          this.historicalDiskIOMetrics = result?.disk_io_history;
+          this.updateHistoricalCharts();
+        },
+        error: (error: { message: string; }) => {
+          console.log(error);
+          this._notification.showError(error.message);
+        }
+      });
+  }
+
   deviceStats: any = {}
   deviceConnectionStats: any = {}
+  virtualServices: any = [];
+
   getDeviceGroups(): void {
     this.devices = [];
     this.groups = [];
+    this.virtualServices = [];
     // ToDo: Update with actual RoleId
     let roleId = "0"
     let rawPayload = new FormData();
@@ -93,9 +128,12 @@
                 this.groups.push(group?.group_name);
                 group?.device_list.forEach((device: any) => {
                   this.devices.push(device);
+                  if (device?.type.toLowerCase() === 'apv' || device?.type.toLowerCase() === 'vapv') {
+                    this.getAPVVirtualServices(device);
+                  }
                 })
               })
-              this.deviceStats =  this.getDeviceGraphData(this.devices);
+              this.deviceStats = this.getDeviceGraphData(this.devices);
               this.deviceConnectionStats = this.transformChartData(this.deviceStats.types.entries());
               this.connectedDevices = this.devices.filter((device: any) => device?.connection === true).length;
             }
@@ -107,6 +145,20 @@
       })
   }
 
+  getAPVVirtualServices(_device: any): void {
+    this._device.getAPVSLBVirtualServices(_device?.id).pipe(take(1)).subscribe({
+      next: (result: any) => {
+        if (result && result.VirtualService) {
+          let _vs = result.VirtualService;
+          this.virtualServices.push(..._vs)
+        }
+      },
+      error: error => {
+        this._notification.showError(`Error: ${error?.message}`);
+      }
+    })
+  }
+
   transformChartData(deviceData: [string, { connected: number, disconnected: number }][]) {
     const yAxisData: string[] = [];
     const connectedData: number[] = [];
@@ -118,15 +170,15 @@
       disconnectedData.push(status.disconnected);
     });
 
-    return { yAxisData, connectedData, disconnectedData };
+    return {yAxisData, connectedData, disconnectedData};
   }
 
   getDeviceGraphData(devices: any): DeviceGraphData {
-    const totalStatus: DeviceTypeStatus = { connected: 0, disconnected: 0 };
+    const totalStatus: DeviceTypeStatus = {connected: 0, disconnected: 0};
     const typesStatus = new Map<string, DeviceTypeStatus>();
 
     if (!devices || devices.length === 0) {
-      return { total: totalStatus, types: typesStatus };
+      return {total: totalStatus, types: typesStatus};
     }
 
     devices.forEach((device: any) => {
@@ -139,7 +191,7 @@
 
       // Update the per-type counts
       if (!typesStatus.has(device.type)) {
-        typesStatus.set(device.type, { connected: 0, disconnected: 0 });
+        typesStatus.set(device.type, {connected: 0, disconnected: 0});
       }
       const status = typesStatus.get(device.type)!;
       if (device.connection) {
@@ -149,7 +201,7 @@
       }
     });
 
-    return { total: totalStatus, types: typesStatus };
+    return {total: totalStatus, types: typesStatus};
   }
 
   ngOnChanges(changes: SimpleChanges): void {
@@ -173,18 +225,17 @@
         remaining: 100 - this.diskMetrics?.used_percent,
       },
       diskIO: {
-        usage: this.currentSystemMetrics?.diskio?.disk_io_percent,
-        remaining: 100 - this.currentSystemMetrics?.diskio?.disk_io_percent,
+        usage: this.currentSystemMetrics?.disk_io?.disk_io_percent,
+        remaining: 100 - this.currentSystemMetrics?.disk_io?.disk_io_percent,
       }
     }
-
-    this.chartOption1 = {
+    this.systemLoadChartOption2 = {
       title: {
-        text: `CPU - ${_data?.cpu?.usage.toFixed(1)}%`,
+        text: `CPU Usage - ${_data?.cpu?.usage.toFixed(1)}%`,
         left: 'center',
-        top: '60%',
+        top: '80%',
         textStyle: {
-          fontSize: 16,
+          fontSize: 14,
           fontWeight: 'bold',
           color: '#333'
         }
@@ -208,7 +259,7 @@
               value: _data?.cpu?.usage,
               name: 'CPU Usage',
               itemStyle: {
-                color: '#1170cf'
+                color: '#008ac5'
               },
             },
             {
@@ -223,13 +274,13 @@
       ]
     };
 
-    this.chartOption2 = {
+    this.systemLoadChartOption3 = {
       title: {
-        text: `Memory - ${_data?.memory?.usage.toFixed(1)}%`,
+        text: `Memory Usage - ${_data?.memory?.usage.toFixed(1)}%`,
         left: 'center',
-        top: '60%',
+        top: '80%',
         textStyle: {
-          fontSize: 16,
+          fontSize: 14,
           fontWeight: 'bold',
           color: '#333'
         }
@@ -253,7 +304,7 @@
               value: _data?.memory?.usage,
               name: 'Memory Usage',
               itemStyle: {
-                color: '#1170cf'
+                color: '#00c698'
               },
             },
             {
@@ -268,11 +319,11 @@
       ]
     };
 
-    this.chartOption3 = {
+    this.diskChartOption1 = {
       title: {
         text: `Usage - ${_data?.disk?.usage.toFixed(1)}%`,
         left: 'center',
-        top: '60%',
+        top: '80%',
         textStyle: {
           fontSize: 12,
           fontWeight: 'bold',
@@ -312,52 +363,8 @@
         }
       ]
     };
-    this.chartOption4 = {
-      title: {
-        text: `I/O - ${_data?.diskIO?.usage.toFixed(1)}%`,
-        left: 'center',
-        top: '60%',
-        textStyle: {
-          fontSize: 12,
-          fontWeight: 'bold',
-          color: '#333'
-        }
-      },
-      tooltip: {
-        trigger: 'item',
-        formatter: '{b}: {c}%'
-      },
-      series: [
-        {
-          type: 'pie',
-          radius: ['70%', '90%'],
-          center: ['50%', '75%'],
-          startAngle: 180,
-          endAngle: 0,
-          label: {
-            show: false
-          },
-          data: [
-            {
-              value: _data?.diskIO?.usage,
-              name: 'Disk Usage',
-              itemStyle: {
-                color: '#1170cf'
-              },
-            },
-            {
-              value: _data?.diskIO?.remaining,
-              name: 'Remaining',
-              itemStyle: {
-                color: '#E0E0E0'
-              },
-            },
-          ]
-        }
-      ]
-    };
 
-    this.chartOption5 = {
+    this.connectionChartOption1 = {
       tooltip: {
         trigger: 'axis',
         axisPointer: {
@@ -367,10 +374,18 @@
       legend: {
         bottom: 'bottom'
       },
-      xAxis: {
-        type: 'value'
-      },
       yAxis: {
+        type: 'value',
+        axisLabel: {
+          formatter: function (value: number) {
+            if (value % 1 === 0) {
+              return String(value);
+            }
+            return '';
+          },
+        },
+      },
+      xAxis: {
         type: 'category',
         data: this.deviceConnectionStats?.yAxisData
       },
@@ -400,9 +415,189 @@
             focus: 'series'
           },
           data: this.deviceConnectionStats?.disconnectedData
+        }
+      ]
+    };
+
+    this.connectionChartOption2 = {
+      tooltip: {
+        trigger: 'item'
+      },
+      series: [
+        {
+          name: 'Devices Status',
+          type: 'pie',
+          radius: ['40%', '70%'],
+          avoidLabelOverlap: false,
+          label: {
+            show: false,
+            position: 'bottom'
+          },
+          labelLine: {
+            show: false
+          },
+          data: [
+            {value: this.deviceStats?.total?.connected, name: 'Connected', itemStyle: {color: 'green'}},
+            {value: this.deviceStats?.total?.disconnected, name: 'Disconnected', itemStyle: {color: 'red'}}
+          ]
         }
       ]
+    }
+  }
+
+  updateHistoricalCharts() {
+    const cpu_data_formatted: any = this.historicalCPUMetrics.map((d: any) => [d.time, d.cpu_percent]);
+    const memory_data_formatted: any = this.historicalMemoryMetrics.map((d: any) => [d.time, d.mem_percent]);
+
+    const {unit, factor}: any = {unit: 'MB/s', factor: 1024 * 1024};
+    const sent_data_formatted: any = this.historicalNetworkMetrics.map((d: any) => [d.time, d.bytes_sent_bps / factor]);
+    const received_data_formatted: any = this.historicalNetworkMetrics.map((d: any) => [d.time, d.bytes_recv_bps / factor]);
+
+    const disk_io_formatted = this.historicalDiskIOMetrics.map((d: any) => [d.time, d.disk_io_percent]);
+
+    this.systemLoadChartOption1 = {
+      grid: {
+        left: '7%',
+        right: '1%',
+        bottom: '1%',
+        containLabel: true
+      },
+      tooltip: {
+        trigger: 'axis',
+        formatter: (params: any) => {
+          const date = new Date(params[0].value[0]);
+          const formattedTime = date.toLocaleTimeString('en-US', {
+            hour: '2-digit',
+            minute: '2-digit',
+            second: '2-digit',
+            hour12: false
+          });
+          let tooltipContent = `Time: ${formattedTime}<br/>`;
+          params.forEach((item: any) => {
+            tooltipContent += `${item.marker} ${item.seriesName}: ${item.value[1]}<br/>`;
+          });
+          return tooltipContent;
+        }
+      },
+      legend: {
+        data: ['CPU', 'Memory']
+      },
+      xAxis: {
+        type: 'time',
+        name: 'Time'
+      },
+      yAxis: {
+        type: 'value',
+        name: 'Percentage'
+      },
+      series: [
+        {
+          name: 'CPU',
+          type: 'line',
+          data: cpu_data_formatted,
+          color: '#008ac5'
+        },
+        {
+          name: 'Memory',
+          type: 'line',
+          data: memory_data_formatted,
+          color: '#00c698'
+        }
+      ]
     };
+
+    this.networkThroughputChartOption1 = {
+      grid: {
+        left: '7%',
+        right: '1%',
+        bottom: '1%',
+        containLabel: true
+      },
+      tooltip: {
+        trigger: 'axis',
+        formatter: (params: any) => {
+          const date = new Date(params[0].value[0]);
+          const formattedTime = date.toLocaleTimeString('en-US', {
+            hour: '2-digit',
+            minute: '2-digit',
+            second: '2-digit',
+            hour12: false
+          });
+          let tooltipContent = `Time: ${formattedTime}<br/>`;
+          params.forEach((item: any) => {
+            tooltipContent += `${item.marker} ${item.seriesName}: ${item.value[1].toFixed(2)} ${unit}<br/>`;
+          });
+          return tooltipContent;
+        }
+      },
+      legend: {
+        data: ['Sent', 'Received']
+      },
+      xAxis: {
+        type: 'time',
+        name: 'Time'
+      },
+      yAxis: {
+        type: 'value',
+        name: `Bandwidth (${unit})`
+      },
+      series: [
+        {
+          name: 'Sent',
+          type: 'line',
+          data: sent_data_formatted,
+        },
+        {
+          name: 'Received',
+          type: 'line',
+          data: received_data_formatted,
+        }
+      ]
+    };
+
+    this.diskIOChartOption1 = {
+      grid: {
+        left: '7%',
+        right: '1%',
+        bottom: '1%',
+        containLabel: true
+      },
+      tooltip: {
+        trigger: 'axis',
+        formatter: (params: any) => {
+          const date = new Date(params[0].value[0]);
+          const formattedTime = date.toLocaleTimeString('en-US', {
+            hour: '2-digit',
+            minute: '2-digit',
+            second: '2-digit',
+            hour12: false
+          });
+          let tooltipContent = `Time: ${formattedTime}<br/>`;
+          params.forEach((item: any) => {
+            tooltipContent += `${item.marker} ${item.seriesName}: ${item.value[1].toFixed(2)}<br/>`;
+          });
+          return tooltipContent;
+        }
+      },
+      legend: {
+        data: ['Disk I/O',]
+      },
+      xAxis: {
+        type: 'time',
+        name: 'Time'
+      },
+      yAxis: {
+        type: 'value',
+        name: `Percentage %`
+      },
+      series: [
+        {
+          name: 'Disk I/O',
+          type: 'line',
+          data: disk_io_formatted
+        },
+      ]
+    };
   }
 
   dialog = inject(MatDialog);
@@ -457,13 +652,14 @@
   }
 
   ngOnInit() {
-    setTimeout(()=>{
+    setTimeout(() => {
       this.getHistoricalSystemMetrics();
     })
   }
 
   cpuMetrics: any = {};
   memoryMetrics: any = {};
+
   getHistoricalSystemMetrics() {
     this._system.getHistoricalSystemMetrics()
       .pipe(take(1))
@@ -517,12 +713,14 @@
         {
           name: 'CPU',
           type: 'line',
-          data: cpu_data_formatted
+          data: cpu_data_formatted,
+          color: '#008ac5'
         },
         {
           name: 'Memory',
           type: 'line',
-          data: memory_data_formatted
+          data: memory_data_formatted,
+          color: '#00c698'
         }
       ]
     };
@@ -552,12 +750,13 @@
   }
 
   ngOnInit() {
-    setTimeout(()=>{
+    setTimeout(() => {
       this.getHistoricalSystemMetrics();
     })
   }
 
   networkMetrics: any = {};
+
   getHistoricalSystemMetrics() {
     this._system.getHistoricalSystemMetrics()
       .pipe(take(1))
@@ -574,7 +773,7 @@
   }
 
   updateChartOptions() {
-    const { unit, factor }: any = {unit: 'MB/s', factor: 1024 * 1024};
+    const {unit, factor}: any = {unit: 'MB/s', factor: 1024 * 1024};
 
     const sent_data_formatted = this.networkMetrics.map((d: any) => [d.time, d.bytes_sent_bps / factor]);
     const received_data_formatted = this.networkMetrics.map((d: any) => [d.time, d.bytes_recv_bps / factor]);
@@ -649,18 +848,19 @@
   }
 
   ngOnInit() {
-    setTimeout(()=>{
+    setTimeout(() => {
       this.getHistoricalSystemMetrics();
     })
   }
 
   diskIOMetrics: any = {};
+
   getHistoricalSystemMetrics() {
     this._system.getHistoricalSystemMetrics()
       .pipe(take(1))
       .subscribe({
         next: (result: any) => {
-          this.diskIOMetrics = result?.diskio_history;
+          this.diskIOMetrics = result?.disk_io_history;
           this.updateChartOptions();
         },
         error: (error: { message: string; }) => {
@@ -746,11 +946,11 @@
       disconnectedData.push(status.disconnected);
     });
 
-    return { yAxisData, connectedData, disconnectedData };
+    return {yAxisData, connectedData, disconnectedData};
   }
 
   updateChartOptions() {
-    const { yAxisData, connectedData, disconnectedData } = this.transformChartData(this.data.types.entries());
+    const {yAxisData, connectedData, disconnectedData} = this.transformChartData(this.data.types.entries());
     this.chartOption1 = {
       tooltip: {
         trigger: 'axis',
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/enlarge-system-throughput.html
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/enlarge-system-throughput.html	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/dashboard-system-insights/enlarge-system-throughput.html	(working copy)
@@ -1,4 +1,4 @@
-<h2 mat-dialog-title>System Throughput (Last 1 Hour)</h2>
+<h2 mat-dialog-title>Network Throughput (Last 1 Hour)</h2>
 <mat-dialog-content>
   <div echarts [options]="chartOption1" class="chart-container"></div>
 </mat-dialog-content>
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/devices/devices.html
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/devices/devices.html	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/components/sub-components/devices/devices.html	(working copy)
@@ -13,7 +13,7 @@
     <input matInput (keyup)="applyFilter($event)" placeholder="Ex. Array" #input>
   </mat-form-field>
 
-  <table mat-table [dataSource]="dataSource" class="mat-elevation-z1">
+  <table mat-table [dataSource]="dataSource" class="mat-elevation-z1 an-table">
     <ng-container matColumnDef="serial">
       <th mat-header-cell *matHeaderCellDef> No.</th>
       <td mat-cell *matCellDef="let element; let i = index;"> {{ i | globalSerial }}</td>
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/constants/api_urls.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/constants/api_urls.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/constants/api_urls.ts	(working copy)
@@ -159,6 +159,10 @@
   UPDATE_SLB_REAL_SERVICE_URL: `${PREFIX}/real_service`,
   GET_SYSTEM_LATEST_METRICS_URL: `${PREFIX}/system-metrics-latest`,
   GET_SYSTEM_HISTORICAL_METRICS_URL: `${PREFIX}/system-metrics-history`,
+  GET_DEVICES_METRICS_URL: `${PREFIX}/devices-metrics`,
+  GET_TOP_APV_VIRTUAL_METRICS_URL: `${PREFIX}/top-apv-virtual-metrics`,
+  GET_TOP_APV_REAL_METRICS_URL: `${PREFIX}/top-apv-real-metrics`,
+  GET_TOP_APV_LLB_METRICS_URL: `${PREFIX}/top-apv-llb-metrics`,
   // AVX
   GET_AVX_DEVICES_URL: `${PREFIX}/api/cm/virtualization/Host/_get_list_data`,
   ADD_AVX_DEVICE_URL: `${PREFIX}/api/cm/virtualization/Host/_add`,
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/services/system-service.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/services/system-service.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/services/system-service.ts	(working copy)
@@ -457,5 +457,37 @@
 
   getHistoricalSystemMetrics() {
     return this.http.get(URLS.GET_SYSTEM_HISTORICAL_METRICS_URL);
+  }
+
+  getConnectedDevicesMetrics(payload: any) {
+    return this.http.post(URLS.GET_DEVICES_METRICS_URL, payload, {
+      csrf: true,
+      isFormData: false,
+      csrfInFormData: true
+    });
+  }
+
+  getTopAPVVirtualServicesMetrics(payload: any) {
+    return this.http.post(URLS.GET_TOP_APV_VIRTUAL_METRICS_URL, payload, {
+      csrf: true,
+      isFormData: false,
+      csrfInFormData: true
+    });
+  }
+
+  getTopAPVRealServicesMetrics(payload: any) {
+    return this.http.post(URLS.GET_TOP_APV_REAL_METRICS_URL, payload, {
+      csrf: true,
+      isFormData: false,
+      csrfInFormData: true
+    });
   }
+
+  getTopAPVLLBMetrics(payload: any) {
+    return this.http.post(URLS.GET_TOP_APV_LLB_METRICS_URL, payload, {
+      csrf: true,
+      isFormData: false,
+      csrfInFormData: true
+    });
+  }
 }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/shared/shared-module.ts
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/shared/shared-module.ts	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/app/shared/shared-module.ts	(working copy)
@@ -37,6 +37,8 @@
   faClockRotateLeft,
   faRepeat,
   faCircleInfo,
+  faArrowUpLong,
+  faArrowDownLong,
 } from '@fortawesome/free-solid-svg-icons';
 import {
   faBell,
@@ -227,6 +229,8 @@
       faClockRotateLeft,
       faRepeat,
       faCircleInfo,
+      faArrowUpLong,
+      faArrowDownLong,
     );
   }
 }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/styles.scss
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/styles.scss	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/gui/src/styles.scss	(working copy)
@@ -72,6 +72,25 @@
   padding: 3px;
   position: relative;
   z-index: 20;
+  --table-bg: transparent;
+  .an-table {
+    background: var(--table-bg);
+
+    .mat-cell,
+    .mat-header-cell,
+    [mat-cell],
+    [mat-header-cell],
+    .mat-row,
+    .mat-header-row,
+    [mat-row],
+    [mat-header-row] {
+      background: var(--table-bg);
+
+      &:hover {
+        background: var(--table-bg);
+      }
+    }
+  }
 }
 
 /* Filter container with high specificity */
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/apv_services_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/apv_services_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/apv_services_metrics.py	(working copy)
@@ -0,0 +1,87 @@
+from django.http import JsonResponse
+
+from cm.lib.libbasic_operation import oper_log
+from hive.custom_exceptions import generic_exception as ge
+from hive.services.apv_services_metrics import get_top_apv_virtual_services_metrics, get_top_apv_real_services_metrics, \
+    get_top_llb_metrics
+
+
+def handle_get_top_apv_virtual_services_metrics(request, path=None):
+    try:
+        if request.method != 'POST':
+            return JsonResponse({
+                'error': 400,
+                'message': "Invalid HTTP method"
+            }, status=400)
+
+        payload = getattr(request, 'json', {}) or {}
+        agent_hosts = payload.get('agent_host', None)
+        if agent_hosts is not None:
+            if isinstance(agent_hosts, str):
+                agent_hosts = [agent_hosts]
+
+        services_metrics = get_top_apv_virtual_services_metrics(agent_hosts)
+
+        return JsonResponse(services_metrics, safe=False)
+
+    except ge.GenericError as e:
+        oper_log('error', 'system', str(e))
+        return ge.handle_exception(e)
+    except Exception as e:
+        msg = f'Exception while getting top apv virtual services metrics: {str(e)}'
+        oper_log('error', 'system', msg)
+        raise ge.GenericError(500, msg)
+
+
+def handle_get_top_apv_real_services_metrics(request, path=None):
+    try:
+        if request.method != 'POST':
+            return JsonResponse({
+                'error': 400,
+                'message': "Invalid HTTP method"
+            }, status=400)
+
+        payload = getattr(request, 'json', {}) or {}
+        agent_hosts = payload.get('agent_host', None)
+        if agent_hosts is not None:
+            if isinstance(agent_hosts, str):
+                agent_hosts = [agent_hosts]
+
+        services_metrics = get_top_apv_real_services_metrics(agent_hosts)
+
+        return JsonResponse(services_metrics, safe=False)
+
+    except ge.GenericError as e:
+        oper_log('error', 'system', str(e))
+        return ge.handle_exception(e)
+    except Exception as e:
+        msg = f'Exception while getting top apv real services metrics: {str(e)}'
+        oper_log('error', 'system', msg)
+        raise ge.GenericError(500, msg)
+
+
+def handle_get_top_llb_metrics(request, path=None):
+    try:
+        if request.method != 'POST':
+            return JsonResponse({
+                'error': 400,
+                'message': "Invalid HTTP method"
+            }, status=400)
+
+        payload = getattr(request, 'json', {}) or {}
+        agent_hosts = payload.get('agent_host', None)
+        if agent_hosts is not None:
+            if isinstance(agent_hosts, str):
+                agent_hosts = [agent_hosts]
+
+        services_metrics = get_top_llb_metrics(agent_hosts)
+
+        return JsonResponse(services_metrics, safe=False)
+
+    except ge.GenericError as e:
+        oper_log('error', 'system', str(e))
+        return ge.handle_exception(e)
+    except Exception as e:
+        msg = f'Exception while getting top apv llb metrics: {str(e)}'
+        oper_log('error', 'system', msg)
+        raise ge.GenericError(500, msg)
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/devices_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/devices_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/devices_metrics.py	(working copy)
@@ -0,0 +1,34 @@
+from django.http import JsonResponse
+
+from cm.lib.libbasic_operation import oper_log
+from hive.custom_exceptions import generic_exception as ge
+from hive.services.devices_metrics import get_top_devices_metrics
+from hive.utils import andebug
+
+
+def handle_get_top_devices_metrics(request, path=None):
+    try:
+        if request.method != 'POST':
+            return JsonResponse({
+                'error': 400,
+                'message': "Invalid HTTP method"
+            }, status=400)
+
+        payload = getattr(request, 'json', {}) or {}
+        agent_hosts = payload.get('agent_host', None)
+        if agent_hosts is not None:
+            if isinstance(agent_hosts, str):
+                agent_hosts = [agent_hosts]
+
+        devices_metrics = get_top_devices_metrics(agent_hosts)
+
+        return JsonResponse(devices_metrics, safe=False)
+
+    except ge.GenericError as e:
+        oper_log('error', 'system', str(e))
+        return ge.handle_exception(e)
+    except Exception as e:
+        andebug('an.model.cli', e)
+        msg = f'Exception while getting latest metrics: {str(e)}'
+        oper_log('error', 'system', msg)
+        raise ge.GenericError(500, msg)
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/system_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/system_metrics.py	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/controller/system_metrics.py	(working copy)
@@ -1,6 +1,5 @@
-import json
+from django.http import JsonResponse
 
-from django.http import HttpResponse, JsonResponse
 from cm.lib.libbasic_operation import oper_log
 from hive.custom_exceptions import generic_exception as ge
 from hive.services.system_metrics import get_latest_system_metrics, get_historical_system_metrics
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/apv_services_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/apv_services_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/apv_services_metrics.py	(working copy)
@@ -0,0 +1,58 @@
+class VirtualServicesMetrics:
+    def __init__(self, metric, agent_host, service_name, value, received=None, sent=None):
+        self.metric = metric  # "connections", "requests", or "network"
+        self.agent_host = agent_host
+        self.service_name = service_name
+        self.value = float(value) if value is not None else None
+        self.received = int(received) if received is not None else None
+        self.sent = int(sent) if sent is not None else None
+
+    def to_dict(self):
+        return {
+            'metric': self.metric,
+            'agent_host': self.agent_host,
+            'service_name': self.service_name,
+            'value': self.value,
+            'received': self.received,
+            'sent': self.sent
+        }
+
+
+class RealServicesMetrics:
+    def __init__(self, metric, agent_host, service_name, value, received=None, sent=None):
+        self.metric = metric  # "connections", "hits", or "network"
+        self.agent_host = agent_host
+        self.service_name = service_name
+        self.value = float(value) if value is not None else None
+        self.received = int(received) if received is not None else None
+        self.sent = int(sent) if sent is not None else None
+
+    def to_dict(self):
+        return {
+            'metric': self.metric,
+            'agent_host': self.agent_host,
+            'service_name': self.service_name,
+            'value': self.value,
+            'received': self.received,
+            'sent': self.sent
+        }
+
+
+class LLBMetrics:
+    def __init__(self, metric, agent_host, link_name, value, received=None, sent=None):
+        self.metric = metric            # "hits", "connections", "throughput"
+        self.agent_host = agent_host
+        self.link_name = link_name
+        self.value = float(value) if value is not None else None
+        self.received = int(received) if received is not None else None
+        self.sent = int(sent) if sent is not None else None
+
+    def to_dict(self):
+        return {
+            "metric": self.metric,
+            "agent_host": self.agent_host,
+            "link_name": self.link_name,
+            "value": self.value,
+            "received": self.received,
+            "sent": self.sent
+        }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/db_client.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/db_client.py	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/db_client.py	(working copy)
@@ -1,10 +1,26 @@
+import os
+
 import psycopg2
-import json
-import time
 
 from hive.custom_exceptions import generic_exception as ge
 
+DB_HOST = os.environ.get("TIMESCALEDB_HOST", "localhost")
+DB_NAME = os.environ.get("TIMESCALEDB_DB", "amp_ts")
+DB_USER = os.environ.get("TIMESCALEDB_USER", "amp_ts_user")
+DB_PASSWORD = os.environ.get("TIMESCALEDB_PASSWORD", "Array@123$")
+DB_PORT = int(os.environ.get("TIMESCALEDB_PORT", 5432))
 
+
+# ToDo: Implement Connection Pool
+def get_db_connection():
+    return psycopg2.connect(
+        host=DB_HOST,
+        dbname=DB_NAME,
+        user=DB_USER,
+        password=DB_PASSWORD
+    )
+
+
 class DBClient:
 
     def __init__(self):
@@ -22,13 +38,7 @@
         conn = None
         cur = None
         try:
-            conn = psycopg2.connect(
-                dbname="amp_ts",
-                user="amp_ts_user",
-                password="Array@123$",
-                host="localhost",
-                port=5432
-            )
+            conn = get_db_connection()
             cur = conn.cursor()
 
             # Execute query (with params if provided)
@@ -38,9 +48,9 @@
                 cur.execute(req_dict["query"])
 
             rows = cur.fetchall()
-            colnames = [desc[0] for desc in cur.description]
-            result = [dict(zip(colnames, row)) for row in rows]
-
+            col_names = [desc[0] for desc in cur.description]
+            result = [dict(zip(col_names, row)) for row in rows]
+            # ToDo: Remove the HTTP Status Code notion from DB layer and add proper Exception Handlers.
             return {
                 "status": 200,
                 "message": "success",
@@ -68,3 +78,25 @@
                 cur.close()
             if conn:
                 conn.close()
+
+
+def with_db_connection(func):
+    def wrapper(*args, **kwargs):
+        conn = None
+        cur = None
+        try:
+            conn = get_db_connection()
+            cur = conn.cursor()
+            result = func(cur, *args, **kwargs)
+            conn.commit()
+            return result
+        except (Exception, psycopg2.DatabaseError) as error:
+            # ToDo: Integrate with Exception handlers once available.
+            print(f"Error in {func.__name__}: {error}")
+        finally:
+            if cur:
+                cur.close()
+            if conn:
+                conn.close()
+
+    return wrapper
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/devices_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/devices_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/devices_metrics.py	(working copy)
@@ -0,0 +1,16 @@
+class DevicesMetrics:
+    def __init__(self, metric, agent_host, value, total_in=None, total_out=None):
+        self.metric = metric  # "cpu", "memory", or "network"
+        self.agent_host = agent_host
+        self.value = float(value) if value is not None else None
+        self.total_in = int(total_in) if total_in is not None else None
+        self.total_out = int(total_out) if total_out is not None else None
+
+    def to_dict(self):
+        return {
+            'metric': self.metric,
+            'agent_host': self.agent_host,
+            'value': self.value,
+            'total_in': self.total_in,
+            'total_out': self.total_out
+        }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/system_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/system_metrics_database.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/system_metrics.py	(working copy)
@@ -0,0 +1,72 @@
+class SystemMetrics:
+    def __init__(self, time, host, cpu_percent=None, mem_percent=None, disk_io_percent=None, read_speed=None,
+                 write_speed=None):
+        self.time = time
+        self.host = host
+        self.cpu_percent = cpu_percent
+        self.mem_percent = mem_percent
+        self.disk_io_percent = disk_io_percent
+        self.read_speed = read_speed
+        self.write_speed = write_speed
+
+    def to_dict(self):
+        data = {'time': self.time.isoformat() if self.time else None, 'host': self.host}
+
+        if self.cpu_percent is not None:
+            data['cpu_percent'] = float(round(self.cpu_percent, 2))
+
+        if self.mem_percent is not None:
+            data['mem_percent'] = float(round(self.mem_percent, 2))
+
+        if self.disk_io_percent is not None:
+            data['disk_io_percent'] = float(round(self.disk_io_percent, 2))
+
+        if self.read_speed is not None:
+            data['read_speed'] = float(round(self.read_speed, 2))
+
+        if self.write_speed is not None:
+            data['write_speed'] = float(round(self.write_speed, 2))
+
+        return data
+
+
+class DiskMetrics:
+    def __init__(self, time, host, device, path, total, used, free, used_percent):
+        self.time = time
+        self.host = host
+        self.device = device
+        self.path = path
+        self.total = total
+        self.used = used
+        self.free = free
+        self.used_percent = used_percent
+
+    def to_dict(self):
+        return {
+            'time': self.time.isoformat() if self.time else None,
+            'host': self.host,
+            'device': self.device,
+            'path': self.path,
+            'total_bytes': float(self.total),
+            'used_bytes': float(self.used),
+            'free_bytes': float(self.free),
+            'used_percent': float(round(self.used_percent, 2))
+        }
+
+
+class NetworkMetrics:
+    def __init__(self, time, host, interface, bytes_sent_bps, bytes_recv_bps):
+        self.time = time
+        self.host = host
+        self.interface = interface
+        self.bytes_sent_bps = bytes_sent_bps
+        self.bytes_recv_bps = bytes_recv_bps
+
+    def to_dict(self):
+        return {
+            'time': self.time.isoformat() if self.time else None,
+            'host': self.host,
+            'interface': self.interface,
+            'bytes_sent_bps': float(round(self.bytes_sent_bps, 2)) if self.bytes_sent_bps is not None else None,
+            'bytes_recv_bps': float(round(self.bytes_recv_bps, 2)) if self.bytes_recv_bps is not None else None
+        }
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/system_metrics_database.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/system_metrics_database.py	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/db/system_metrics_database.py	(nonexistent)
@@ -1,109 +0,0 @@
-import psycopg2
-import os
-
-from hive.utils import andebug
-
-DB_HOST = os.environ.get("TIMESCALEDB_HOST", "localhost")
-DB_NAME = os.environ.get("TIMESCALEDB_DB", "amp_ts")
-DB_USER = os.environ.get("TIMESCALEDB_USER", "amp_ts_user")
-DB_PASSWORD = os.environ.get("TIMESCALEDB_PASSWORD", "Array@123$")
-
-
-class SystemMetrics:
-    def __init__(self, time, host, cpu_percent=None, mem_percent=None, disk_io_percent=None, read_speed=None,
-                 write_speed=None):
-        self.time = time
-        self.host = host
-        self.cpu_percent = cpu_percent
-        self.mem_percent = mem_percent
-        self.disk_io_percent = disk_io_percent
-        self.read_speed = read_speed
-        self.write_speed = write_speed
-
-    def to_dict(self):
-        data = {'time': self.time.isoformat() if self.time else None, 'host': self.host}
-
-        if self.cpu_percent is not None:
-            data['cpu_percent'] = float(round(self.cpu_percent, 2))
-
-        if self.mem_percent is not None:
-            data['mem_percent'] = float(round(self.mem_percent, 2))
-
-        if self.disk_io_percent is not None:
-            data['disk_io_percent'] = float(round(self.disk_io_percent, 2))
-
-        if self.read_speed is not None:
-            data['read_speed'] = float(round(self.read_speed, 2))
-
-        if self.write_speed is not None:
-            data['write_speed'] = float(round(self.write_speed, 2))
-
-        return data
-
-
-class DiskMetrics:
-    def __init__(self, time, host, device, path, total, used, free, used_percent):
-        self.time = time
-        self.host = host
-        self.device = device
-        self.path = path
-        self.total = total
-        self.used = used
-        self.free = free
-        self.used_percent = used_percent
-
-    def to_dict(self):
-        return {
-            'time': self.time.isoformat() if self.time else None,
-            'host': self.host,
-            'device': self.device,
-            'path': self.path,
-            'total_bytes': float(self.total),
-            'used_bytes': float(self.used),
-            'free_bytes': float(self.free),
-            'used_percent': float(round(self.used_percent, 2))
-        }
-
-
-class NetworkMetrics:
-    def __init__(self, time, host, interface, bytes_sent_bps, bytes_recv_bps):
-        self.time = time
-        self.host = host
-        self.interface = interface
-        self.bytes_sent_bps = bytes_sent_bps
-        self.bytes_recv_bps = bytes_recv_bps
-
-    def to_dict(self):
-        return {
-            'time': self.time.isoformat() if self.time else None,
-            'host': self.host,
-            'interface': self.interface,
-            'bytes_sent_bps': float(round(self.bytes_sent_bps, 2)) if self.bytes_sent_bps is not None else None,
-            'bytes_recv_bps': float(round(self.bytes_recv_bps, 2)) if self.bytes_recv_bps is not None else None
-        }
-
-
-def get_db_connection():
-    return psycopg2.connect(
-        host=DB_HOST,
-        dbname=DB_NAME,
-        user=DB_USER,
-        password=DB_PASSWORD
-    )
-
-
-def with_db_connection(func):
-    def wrapper(*args, **kwargs):
-        conn = None
-        try:
-            conn = get_db_connection()
-            result = func(conn, *args, **kwargs)
-            return result
-        except (Exception, psycopg2.DatabaseError) as error:
-            andebug('an.model.cli', error)
-            print(f"Error in {func.__name__}: {error}")
-        finally:
-            if conn:
-                conn.close()
-
-    return wrapper
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/__init__.py	(added)
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/__init__.py	(revision 0)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/__init__.py	(revision 0)
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/apv_services_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/apv_services_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/apv_services_metrics.py	(working copy)
@@ -0,0 +1,363 @@
+from hive.db.apv_services_metrics import VirtualServicesMetrics, RealServicesMetrics, LLBMetrics
+from hive.db.db_client import with_db_connection
+
+
+class VirtualServicesMetricsRepo:
+    @staticmethod
+    @with_db_connection
+    def get_top_virtual_services_metrics(cur, agent_hosts=None, interval_seconds=20, limit=5):
+        """
+        Fetch top Hits, Connections, and Network metrics from apv_virtual_stats
+        - agent_hosts: optional list of agent hosts to filter
+        - interval_seconds: look-back interval for metrics
+        - limit: top N metrics per category
+        """
+        # Build agent_host filter
+        host_filter = ""
+        params = []
+        if agent_hosts:
+            placeholders = ','.join(['%s'] * len(agent_hosts))
+            host_filter = f"AND agent_host IN ({placeholders})"
+            params.extend(agent_hosts)
+
+        _query = f"""
+        WITH HitsDeltas AS (
+            SELECT
+                ServerId AS service_name,
+                agent_host,
+                MAX(total_hits) - MIN(total_hits) AS hits
+            FROM apv_virtual_stats
+            WHERE time >= NOW() - INTERVAL '{interval_seconds} seconds'
+            {host_filter}
+            GROUP BY ServerId, agent_host
+        ),
+        HitsTop AS (
+            SELECT
+                'hits' AS metric,
+                agent_host,
+                service_name,
+                hits AS value,
+                NULL::bigint AS received,
+                NULL::bigint AS sent
+            FROM HitsDeltas
+            ORDER BY hits DESC
+            LIMIT {limit}
+        ),
+        ConnLatest AS (
+            SELECT DISTINCT ON (ServerId, agent_host)
+                ServerId AS service_name,
+                agent_host,
+                ConnCnt
+            FROM apv_virtual_stats
+            WHERE time >= NOW() - INTERVAL '{interval_seconds} seconds'
+            {host_filter}
+            ORDER BY ServerId, agent_host, time DESC
+        ),
+        ConnTop AS (
+            SELECT
+                'connections' AS metric,
+                agent_host,
+                service_name,
+                ConnCnt AS value,
+                NULL::bigint AS received,
+                NULL::bigint AS sent
+            FROM ConnLatest
+            ORDER BY ConnCnt DESC
+            LIMIT {limit}
+        ),
+        NetLatest AS (
+            SELECT DISTINCT ON (ServerId, agent_host)
+                ServerId AS service_name,
+                agent_host,
+                InBytePerSec,
+                OutBytePerSec
+            FROM apv_virtual_stats
+            WHERE time >= NOW() - INTERVAL '{interval_seconds} seconds'
+            {host_filter}
+            ORDER BY ServerId, agent_host, time DESC
+        ),
+        NetTop AS (
+            SELECT
+                'network' AS metric,
+                agent_host,
+                service_name,
+                (InBytePerSec + OutBytePerSec) AS value,
+                InBytePerSec AS received,
+                OutBytePerSec AS sent
+            FROM NetLatest
+            ORDER BY (InBytePerSec + OutBytePerSec) DESC
+            LIMIT {limit}
+        )
+        SELECT *
+        FROM (
+            SELECT * FROM HitsTop
+            UNION ALL
+            SELECT * FROM ConnTop
+            UNION ALL
+            SELECT * FROM NetTop
+        ) t
+        ORDER BY metric, value DESC;
+        """
+
+        cur.execute(_query, params)
+        rows = cur.fetchall()
+        cur.close()
+
+        # Convert rows to VirtualServicesMetrics objects
+        metrics_list = []
+        for row in rows:
+            metric_obj = VirtualServicesMetricsRepo.parse_virtual_service_metric(row)
+            if metric_obj:
+                metrics_list.append(metric_obj)
+        return metrics_list
+
+    @staticmethod
+    def parse_virtual_service_metric(row):
+        if not row:
+            return None
+        metric, agent_host, service_name, value, received, sent = row
+        return VirtualServicesMetrics(
+            metric=metric,
+            agent_host=agent_host,
+            service_name=service_name,
+            value=value,
+            received=received,
+            sent=sent
+        )
+
+
+class RealServicesMetricsRepo:
+    @staticmethod
+    @with_db_connection
+    def get_top_real_services_metrics(cur, agent_hosts=None, interval_seconds=20, limit=5):
+        """
+        Fetch top Requests, Connections, and Network metrics from apv_real_stats
+        - agent_hosts: optional list of agent hosts to filter
+        - interval_seconds: look-back interval for metrics
+        - limit: top N metrics per category
+        """
+        # Build agent_host filter
+        host_filter = ""
+        params = []
+        if agent_hosts:
+            placeholders = ','.join(['%s'] * len(agent_hosts))
+            host_filter = f"AND agent_host IN ({placeholders})"
+            params.extend(agent_hosts)
+
+        _query = f"""
+        WITH ReqLatest AS (
+            SELECT DISTINCT ON (real_server_id, agent_host)
+                real_server_id AS service_name,
+                agent_host,
+                rs_cnt_of_req AS value
+            FROM apv_real_stats
+            WHERE time >= NOW() - INTERVAL '{interval_seconds} seconds'
+            {host_filter}
+            ORDER BY real_server_id, agent_host, time DESC
+        ),
+        ReqTop AS (
+            SELECT
+                'requests' AS metric,
+                agent_host,
+                service_name,
+                value,
+                NULL::bigint AS received,
+                NULL::bigint AS sent
+            FROM ReqLatest
+            ORDER BY value DESC
+            LIMIT {limit}
+        ),
+        ConnLatest AS (
+            SELECT DISTINCT ON (real_server_id, agent_host)
+                real_server_id AS service_name,
+                agent_host,
+                rs_conn_per_sec AS value
+            FROM apv_real_stats
+            WHERE time >= NOW() - INTERVAL '{interval_seconds} seconds'
+            {host_filter}
+            ORDER BY real_server_id, agent_host, time DESC
+        ),
+        ConnTop AS (
+            SELECT
+                'connections' AS metric,
+                agent_host,
+                service_name,
+                value,
+                NULL::bigint AS received,
+                NULL::bigint AS sent
+            FROM ConnLatest
+            ORDER BY value DESC
+            LIMIT {limit}
+        ),
+        NetLatest AS (
+            SELECT DISTINCT ON (real_server_id, agent_host)
+                real_server_id AS service_name,
+                agent_host,
+                rs_in_byte_per_sec AS received,
+                rs_out_byte_per_sec AS sent,
+                (rs_in_byte_per_sec + rs_out_byte_per_sec) AS value
+            FROM apv_real_stats
+            WHERE time >= NOW() - INTERVAL '{interval_seconds} seconds'
+            {host_filter}
+            ORDER BY real_server_id, agent_host, time DESC
+        ),
+        NetTop AS (
+            SELECT
+                'network' AS metric,
+                agent_host,
+                service_name,
+                value,
+                received * 8 AS received,
+                sent * 8 AS sent
+            FROM NetLatest
+            ORDER BY value DESC
+            LIMIT {limit}
+        )
+        SELECT *
+        FROM (
+            SELECT * FROM ReqTop
+            UNION ALL
+            SELECT * FROM ConnTop
+            UNION ALL
+            SELECT * FROM NetTop
+        ) t
+        ORDER BY metric, value DESC;
+        """
+
+        cur.execute(_query, params)
+        rows = cur.fetchall()
+        cur.close()
+
+        metrics_list = []
+        for row in rows:
+            metric_obj = RealServicesMetricsRepo.parse_real_service_metric(row)
+            if metric_obj:
+                metrics_list.append(metric_obj)
+        return metrics_list
+
+    @staticmethod
+    def parse_real_service_metric(row):
+        if not row:
+            return None
+        metric, agent_host, service_name, value, received, sent = row
+        return RealServicesMetrics(
+            metric=metric,
+            agent_host=agent_host,
+            service_name=service_name,
+            value=value,
+            received=received,
+            sent=sent
+        )
+
+
+class LLBMetricsRepo:
+    @staticmethod
+    @with_db_connection
+    def get_top_llb_metrics(cur, interval_seconds=20, limit=5, agent_hosts=None):
+        # Build agent_host filter
+        host_filter = ""
+        params = {"interval": interval_seconds, "limit": limit}
+        if agent_hosts:
+            host_filter = "AND agent_host = ANY(%(agent_hosts)s)"
+            params["agent_hosts"] = agent_hosts
+
+        query = f"""
+        WITH HitsDeltas AS (
+            SELECT 
+                link_name,
+                agent_host,
+                MAX(link_hits) - MIN(link_hits) AS hits
+            FROM apv_llb_stats
+            WHERE time >= NOW() - INTERVAL '%(interval)s seconds' {host_filter}
+            GROUP BY link_name, agent_host
+        ),
+        HitsTop AS (
+            SELECT
+                'hits' AS metric,
+                agent_host,
+                link_name,
+                hits AS value,
+                NULL::bigint AS received,
+                NULL::bigint AS sent
+            FROM HitsDeltas
+            ORDER BY hits DESC
+            LIMIT %(limit)s
+        ),
+        ConnLatest AS (
+            SELECT DISTINCT ON (link_name, agent_host)
+                link_name,
+                agent_host,
+                link_conn AS conn
+            FROM apv_llb_stats
+            WHERE time >= NOW() - INTERVAL '%(interval)s seconds' {host_filter}
+            ORDER BY link_name, agent_host, time DESC
+        ),
+        ConnTop AS (
+            SELECT
+                'connections' AS metric,
+                agent_host,
+                link_name,
+                conn AS value,
+                NULL::bigint AS received,
+                NULL::bigint AS sent
+            FROM ConnLatest
+            ORDER BY conn DESC
+            LIMIT %(limit)s
+        ),
+        NetLatest AS (
+            SELECT DISTINCT ON (link_name, agent_host)
+                link_name,
+                agent_host,
+                (link_bandwid_in * 8) AS received,
+                (link_bandwid_out * 8) AS sent,
+                ((link_bandwid_in * 8) + (link_bandwid_out * 8)) AS total
+            FROM apv_llb_stats
+            WHERE time >= NOW() - INTERVAL '%(interval)s seconds' {host_filter}
+            ORDER BY link_name, agent_host, time DESC
+        ),
+        NetTop AS (
+            SELECT
+                'throughput' AS metric,
+                agent_host,
+                link_name,
+                total AS value,
+                received,
+                sent
+            FROM NetLatest
+            ORDER BY total DESC
+            LIMIT %(limit)s
+        )
+        SELECT *
+        FROM (
+            SELECT * FROM HitsTop
+            UNION ALL
+            SELECT * FROM ConnTop
+            UNION ALL
+            SELECT * FROM NetTop
+        ) t
+        ORDER BY metric, value DESC;
+        """
+
+        cur.execute(query, params)
+        rows = cur.fetchall()
+
+        metrics_list = []
+        for row in rows:
+            metric_obj = LLBMetricsRepo.parse_llb_metric(row)
+            if metric_obj:
+                metrics_list.append(metric_obj)
+        return metrics_list
+
+    @staticmethod
+    def parse_llb_metric(row):
+        if not row:
+            return None
+        metric, agent_host, link_name, value, received, sent = row
+        return LLBMetrics(
+            metric=metric,
+            agent_host=agent_host,
+            link_name=link_name,
+            value=value,
+            received=received,
+            sent=sent
+        )
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/devices_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/devices_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/devices_metrics.py	(working copy)
@@ -0,0 +1,138 @@
+from hive.db.db_client import with_db_connection
+from hive.db.devices_metrics import DevicesMetrics
+
+
+class DevicesMetricsRepo:
+    @staticmethod
+    @with_db_connection
+    def get_top_devices_metrics(cur, agent_hosts=None, interval_seconds=30, limit=5):
+        """
+        Fetch top CPU, Memory, and Network metrics with optional filtering by agent_hosts.
+        Network throughput calculation is aligned with InfluxDB:
+        - Time-bucketed (10s)
+        - Non-negative deltas
+        - Latest bucket per host
+        """
+        # Build the agent_host filter for LatestMetrics CTE
+        metrics_where = ""
+        metrics_params = []
+        if agent_hosts:
+            placeholders = ','.join(['%s'] * len(agent_hosts))
+            metrics_where = f"WHERE agent_host IN ({placeholders})"
+            metrics_params.extend(agent_hosts)
+
+        # Build the network WHERE clause
+        network_clauses = []
+        network_params = []
+        if agent_hosts:
+            placeholders = ','.join(['%s'] * len(agent_hosts))
+            network_clauses.append(f"agent_host IN ({placeholders})")
+            network_params.extend(agent_hosts)
+        # Always include time filter
+        network_clauses.append(f"time >= NOW() - INTERVAL '{interval_seconds} seconds'")
+        network_where = ""
+        if network_clauses:
+            network_where = "WHERE " + " AND ".join(network_clauses)
+
+        _query = f"""
+        WITH LatestMetrics AS (
+            SELECT
+                agent_host,
+                cpu_usage,
+                net_mem_usage,
+                total_in,
+                total_out,
+                time,
+                ROW_NUMBER() OVER(PARTITION BY agent_host ORDER BY time DESC) AS rn
+            FROM an_device_metrics
+            {metrics_where}
+        ),
+        NetworkBuckets AS (
+            SELECT
+                agent_host,
+                time_bucket('10 seconds', time) AS bucket_time,
+                MAX(total_in) AS total_in,
+                MAX(total_out) AS total_out
+            FROM an_device_metrics
+            {network_where}
+            GROUP BY agent_host, time_bucket('10 seconds', time)
+        ),
+        NetworkDeltas AS (
+            SELECT
+                agent_host,
+                bucket_time,
+                GREATEST(total_in - LAG(total_in) OVER (PARTITION BY agent_host ORDER BY bucket_time), 0) / 10.0 AS received,
+                GREATEST(total_out - LAG(total_out) OVER (PARTITION BY agent_host ORDER BY bucket_time), 0) / 10.0 AS sent
+            FROM NetworkBuckets
+        ),
+        LatestNetworkRates AS (
+            SELECT
+                agent_host,
+                received,
+                sent,
+                (received + sent) AS total,
+                ROW_NUMBER() OVER (PARTITION BY agent_host ORDER BY bucket_time DESC) AS rn
+            FROM NetworkDeltas
+        ),
+        CpuTop AS (
+            SELECT 'cpu' AS metric, agent_host, cpu_usage AS value,
+                   NULL::bigint AS total_in, NULL::bigint AS total_out
+            FROM LatestMetrics
+            WHERE rn = 1
+            ORDER BY cpu_usage DESC
+            LIMIT {limit}
+        ),
+        MemTop AS (
+            SELECT 'memory' AS metric, agent_host, net_mem_usage AS value,
+                   NULL::bigint AS total_in, NULL::bigint AS total_out
+            FROM LatestMetrics
+            WHERE rn = 1
+            ORDER BY net_mem_usage DESC
+            LIMIT {limit}
+        ),
+        NetTop AS (
+            SELECT 'network' AS metric, agent_host, NULL::bigint AS value,
+                   received AS total_in, sent AS total_out
+            FROM LatestNetworkRates
+            WHERE rn = 1
+            ORDER BY total DESC
+            LIMIT {limit}
+        )
+        SELECT *
+        FROM (
+            SELECT * FROM CpuTop
+            UNION ALL
+            SELECT * FROM MemTop
+            UNION ALL
+            SELECT * FROM NetTop
+        ) t
+        ORDER BY metric, value DESC;
+        """
+
+        # Combine parameters for execution
+        params = metrics_params + network_params
+
+        cur.execute(_query, params)
+        rows = cur.fetchall()
+        cur.close()
+
+        # Convert rows to DevicesMetrics objects
+        metrics_list = []
+        for row in rows:
+            metric_obj = DevicesMetricsRepo.parse_host_metric(row)
+            if metric_obj:
+                metrics_list.append(metric_obj)
+        return metrics_list
+
+    @staticmethod
+    def parse_host_metric(row):
+        if not row:
+            return None
+        metric, agent_host, value, total_in, total_out = row
+        return DevicesMetrics(
+            metric=metric,
+            agent_host=agent_host,
+            value=value,
+            total_in=total_in,
+            total_out=total_out
+        )
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/system_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/system_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/repositories/system_metrics.py	(working copy)
@@ -0,0 +1,264 @@
+from hive.db.db_client import with_db_connection
+from hive.db.system_metrics import SystemMetrics, NetworkMetrics, DiskMetrics
+
+
+class SystemMetricsRepo:
+    @staticmethod
+    @with_db_connection
+    def get_latest_cpu(cur, host="AN"):
+        cpu_query = "SELECT time, host, 100 - usage_idle as cpu_percent FROM cpu WHERE time IN (SELECT max(time) FROM cpu WHERE host = %s) AND host = %s AND cpu = 'cpu-total' ORDER BY time DESC LIMIT 1;"
+        cur.execute(cpu_query, (host, host))
+        result = cur.fetchone()
+        cur.close()
+        if result:
+            time, host, cpu_percent = result
+            return SystemMetrics(time=time, host=host, cpu_percent=cpu_percent)
+        return None
+
+    @staticmethod
+    @with_db_connection
+    def get_latest_disk_io(cur, host="AN"):
+        disk_query = """
+                         SELECT
+                             bucket_time,
+                             ROUND(LEAST((SUM(io_time_total_ms) * 100.0 / 60000), 100), 2) AS disk_io_percent,
+                             ROUND(SUM(read_bytes_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS read_speed_bps,
+                             ROUND(SUM(write_bytes_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS write_speed_bps
+                         FROM (
+                                  SELECT
+                                      time_bucket('1 minute', time) AS bucket_time,
+                                      GREATEST(io_time::BIGINT - LAG(io_time) OVER (PARTITION BY host ORDER BY time), 0) AS io_time_total_ms,
+                                      GREATEST(read_bytes::BIGINT - LAG(read_bytes) OVER (PARTITION BY host ORDER BY time), 0) AS read_bytes_diff,
+                                      GREATEST(write_bytes::BIGINT - LAG(write_bytes) OVER (PARTITION BY host ORDER BY time), 0) AS write_bytes_diff,
+                                      EXTRACT(EPOCH FROM (time - LAG(time) OVER (PARTITION BY host ORDER BY time))) AS time_diff_sec
+                                  FROM diskio
+                                  WHERE host = %s
+                              ) sub
+                         WHERE io_time_total_ms IS NOT NULL
+                         GROUP BY bucket_time
+                         ORDER BY bucket_time DESC
+                         LIMIT 1;
+                         """
+        cur.execute(disk_query, (host,))
+        result = cur.fetchone()
+        cur.close()
+        if result:
+            time, disk_io_percent, read_speed, write_speed = result
+            return SystemMetrics(time=time, host=host, disk_io_percent=disk_io_percent, read_speed=read_speed,
+                                 write_speed=write_speed)
+        return None
+
+    @staticmethod
+    @with_db_connection
+    def get_latest_memory(cur, host="AN"):
+        mem_query = "SELECT time, host, used_percent as mem_percent FROM mem WHERE time IN (SELECT max(time) FROM mem WHERE host = %s) AND host = %s ORDER BY time DESC LIMIT 1;"
+        cur.execute(mem_query, (host, host))
+        result = cur.fetchone()
+        cur.close()
+        if result:
+            time, host, mem_percent = result
+            return SystemMetrics(time=time, host=host, mem_percent=mem_percent)
+        return None
+
+    @staticmethod
+    @with_db_connection
+    def get_latest_disk_usage(cur, host="AN"):
+        disk_query = """
+                     SELECT time,
+                            host,
+                            device,
+                            path,
+                            total,
+                            used,
+                            free,
+                            used_percent
+                     FROM disk
+                     WHERE (host, device, time) IN (SELECT host,
+                                                           device,
+                                                           MAX(time)
+                                                    FROM disk
+                                                    WHERE host = %s
+                                                      AND path NOT LIKE 'tmpfs'
+                                                    GROUP BY host, device)
+                     ORDER BY device ASC; \
+                     """
+
+        cur.execute(disk_query, (host,))
+        results = cur.fetchall()
+        cur.close()
+        metrics_list = []
+        for time, host, device, path, total, used, free, used_percent in results:
+            metrics_list.append(DiskMetrics(
+                time=time,
+                host=host,
+                device=device,
+                path=path,
+                total=total,
+                used=used,
+                free=free,
+                used_percent=used_percent
+            ))
+        return [m.to_dict() for m in metrics_list]
+
+    @staticmethod
+    @with_db_connection
+    def get_latest_throughput(cur, host="AN"):
+        net_query = """
+                    SELECT
+                        bucket_time,
+                        interface,
+                        ROUND(SUM(bytes_sent_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS bytes_sent_bps,
+                        ROUND(SUM(bytes_recv_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS bytes_recv_bps
+                    FROM (
+                             SELECT
+                                 time_bucket('1 minute', time) AS bucket_time,
+                                 interface,
+                                 GREATEST(bytes_sent::BIGINT - LAG(bytes_sent) OVER (PARTITION BY host, interface ORDER BY time), 0) AS bytes_sent_diff,
+                                 GREATEST(bytes_recv::BIGINT - LAG(bytes_recv) OVER (PARTITION BY host, interface ORDER BY time), 0) AS bytes_recv_diff,
+                                 EXTRACT(EPOCH FROM (time - LAG(time) OVER (PARTITION BY host, interface ORDER BY time))) AS time_diff_sec
+                             FROM net
+                             WHERE host = %s AND interface NOT LIKE 'lo' AND interface NOT LIKE 'all'
+                         ) sub
+                    WHERE bytes_sent_diff IS NOT NULL
+                    GROUP BY bucket_time, interface
+                    ORDER BY bucket_time DESC
+                    LIMIT 1;
+                    """
+        cur.execute(net_query, (host,))
+        results = cur.fetchall()
+        cur.close()
+
+        metrics_list = []
+        for time, interface, bytes_sent, bytes_recv in results:
+            metrics_list.append(NetworkMetrics(
+                time=time,
+                host=host,
+                interface=interface,
+                bytes_sent_bps=bytes_sent,
+                bytes_recv_bps=bytes_recv
+            ))
+        return [m.to_dict() for m in metrics_list]
+
+    @staticmethod
+    @with_db_connection
+    def get_historical_cpu(cur, bucket_interval, start_time, end_time, host='AN'):
+        cpu_query = """
+                    SELECT time_bucket(%s, time)        AS bucket_time,
+                           last(100 - usage_idle, time) AS cpu_usage
+                    FROM cpu
+                    WHERE time BETWEEN %s AND %s
+                      AND host = %s
+                      AND cpu = 'cpu-total'
+                    GROUP BY bucket_time
+                    ORDER BY bucket_time ASC; \
+                    """
+        cur.execute(cpu_query, (bucket_interval, start_time, end_time, host))
+        results = cur.fetchall()
+        cur.close()
+
+        metrics_list = []
+        for time_bucket, usage in results:
+            metrics_list.append(SystemMetrics(
+                time=time_bucket,
+                host=host,
+                cpu_percent=usage
+            ))
+        return [m.to_dict() for m in metrics_list]
+
+    @staticmethod
+    @with_db_connection
+    def get_historical_memory(cur, bucket_interval, start_time, end_time, host='AN'):
+        mem_query = """
+                    SELECT time_bucket(%s, time)    AS bucket_time,
+                           last(used_percent, time) AS mem_usage
+                    FROM mem
+                    WHERE time BETWEEN %s AND %s
+                      AND host = %s
+                    GROUP BY bucket_time
+                    ORDER BY bucket_time ASC; \
+                    """
+        cur.execute(mem_query, (bucket_interval, start_time, end_time, host))
+        results = cur.fetchall()
+        cur.close()
+
+        metrics_list = []
+        for time_bucket, usage in results:
+            metrics_list.append(SystemMetrics(
+                time=time_bucket,
+                host=host,
+                mem_percent=usage
+            ))
+        return [m.to_dict() for m in metrics_list]
+
+    @staticmethod
+    @with_db_connection
+    def get_historical_disk_io(cur, bucket_interval, start_time, end_time, host='AN'):
+        disk_io_query = """
+                       SELECT bucket_time,
+                              ROUND(LEAST((disk_io_total_ms * 100.0 / 60000), 100), 2) AS disk_io_percent
+                       FROM (SELECT time_bucket('1 minute', time)                            AS bucket_time,
+                                    SUM(GREATEST(io_time::BIGINT - prev_io_time::BIGINT, 0)) AS disk_io_total_ms
+                             FROM (SELECT time,
+                                          io_time,
+                                          LAG(io_time) OVER (PARTITION BY host ORDER BY time) AS prev_io_time
+                                   FROM diskio
+                                   WHERE host = %s
+                                     AND time BETWEEN %s AND %s) sub
+                             WHERE prev_io_time IS NOT NULL
+                             GROUP BY bucket_time) final
+                       ORDER BY bucket_time ASC; \
+                       """
+        cur.execute(disk_io_query, (host, start_time, end_time))
+        results = cur.fetchall()
+        cur.close()
+
+        metrics_list = []
+        for time_bucket, usage in results:
+            metrics_list.append(SystemMetrics(
+                time=time_bucket,
+                host=host,
+                disk_io_percent=usage
+            ))
+        return [m.to_dict() for m in metrics_list]
+
+    @staticmethod
+    @with_db_connection
+    def get_historical_throughput(cur, bucket_interval, start_time, end_time, host='AN'):
+        net_query = """
+                    SELECT bucket_time,
+                           interface,
+                           ROUND(SUM(bytes_sent_diff) * 8 / GREATEST(1, SUM(time_diff_sec)),
+                                 2)                                                                       AS bytes_sent_bps,
+                           ROUND(SUM(bytes_recv_diff) * 8 / GREATEST(1, SUM(time_diff_sec)), 2) AS bytes_recv_bps
+                    FROM (SELECT time_bucket('1 minute', time)                                                            AS bucket_time,
+                                 interface,
+                                 GREATEST(bytes_sent::BIGINT -
+                                          LAG(bytes_sent) OVER (PARTITION BY host, interface ORDER BY time),
+                                          0)                                                                              AS bytes_sent_diff,
+                                 GREATEST(bytes_recv::BIGINT -
+                                          LAG(bytes_recv) OVER (PARTITION BY host, interface ORDER BY time),
+                                          0)                                                                              AS bytes_recv_diff,
+                                 EXTRACT(EPOCH FROM
+                                         (time - LAG(time) OVER (PARTITION BY host, interface ORDER BY time)))            AS time_diff_sec
+                          FROM net
+                          WHERE host = %s
+                            AND interface NOT LIKE 'lo' AND interface NOT LIKE 'all'
+                            AND time BETWEEN %s AND %s) sub
+                    WHERE bytes_sent_diff IS NOT NULL
+                    GROUP BY bucket_time, interface
+                    ORDER BY bucket_time ASC; \
+                    """
+        cur.execute(net_query, (host, start_time, end_time))
+        results = cur.fetchall()
+        cur.close()
+
+        metrics_list = []
+        for time, interface, bytes_sent, bytes_recv in results:
+            metrics_list.append(NetworkMetrics(
+                time=time,
+                host=host,
+                interface=interface,
+                bytes_sent_bps=bytes_sent,
+                bytes_recv_bps=bytes_recv
+            ))
+        return [m.to_dict() for m in metrics_list]
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/apv_services_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/apv_services_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/apv_services_metrics.py	(working copy)
@@ -0,0 +1,77 @@
+from hive.repositories.apv_services_metrics import VirtualServicesMetricsRepo, RealServicesMetricsRepo, LLBMetricsRepo
+
+
+def sanitize_metrics(metrics_list):
+    sanitized = []
+    for m in metrics_list:
+        d = m.to_dict() if hasattr(m, "to_dict") else dict(m)
+        if d['metric'] in ('connections', 'requests', 'hits'):
+            d.pop('received', None)
+            d.pop('sent', None)
+        elif d['metric'] == 'network':
+            d.pop('value', None)
+        sanitized.append(d)
+    return sanitized
+
+
+def get_top_apv_virtual_services_metrics(agent_hosts=None, interval=30, limit=5):
+    """
+    Wrapper to fetch top devices' metrics.
+
+    :param agent_hosts: list of hostnames to filter (or None for all)
+    :param interval: interval in seconds for network rate calculation
+    :param limit: top N hosts per metric
+    :return: list of dicts representing metrics
+    """
+    metrics_objects = VirtualServicesMetricsRepo.get_top_virtual_services_metrics(
+        agent_hosts=agent_hosts,
+        interval_seconds=interval,
+        limit=limit
+    )
+
+    metrics_list = [m.to_dict() for m in metrics_objects]
+
+    metrics_list = sanitize_metrics(metrics_list)
+    return metrics_list
+
+
+def get_top_apv_real_services_metrics(agent_hosts=None, interval=30, limit=5):
+    """
+    Wrapper to fetch top devices' metrics.
+
+    :param agent_hosts: list of hostnames to filter (or None for all)
+    :param interval: interval in seconds for network rate calculation
+    :param limit: top N hosts per metric
+    :return: list of dicts representing metrics
+    """
+    metrics_objects = RealServicesMetricsRepo.get_top_real_services_metrics(
+        agent_hosts=agent_hosts,
+        interval_seconds=interval,
+        limit=limit
+    )
+
+    metrics_list = [m.to_dict() for m in metrics_objects]
+
+    metrics_list = sanitize_metrics(metrics_list)
+    return metrics_list
+
+
+def get_top_llb_metrics(agent_hosts=None, interval=30, limit=5):
+    """
+    Wrapper to fetch top devices' metrics.
+
+    :param agent_hosts: list of hostnames to filter (or None for all)
+    :param interval: interval in seconds for network rate calculation
+    :param limit: top N hosts per metric
+    :return: list of dicts representing metrics
+    """
+    metrics_objects = LLBMetricsRepo.get_top_llb_metrics(
+        agent_hosts=agent_hosts,
+        interval_seconds=interval,
+        limit=limit
+    )
+
+    metrics_list = [m.to_dict() for m in metrics_objects]
+
+    metrics_list = sanitize_metrics(metrics_list)
+    return metrics_list
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/devices_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/devices_metrics.py	(nonexistent)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/devices_metrics.py	(working copy)
@@ -0,0 +1,36 @@
+from hive.repositories.devices_metrics import DevicesMetricsRepo
+
+
+def sanitize_metrics(metrics_list):
+    sanitized = []
+    for m in metrics_list:
+        d = m.to_dict() if hasattr(m, "to_dict") else dict(m)
+        if d['metric'] in ('cpu', 'memory'):
+            d.pop('total_in', None)
+            d.pop('total_out', None)
+        elif d['metric'] == 'network':
+            d.pop('value', None)
+        sanitized.append(d)
+    return sanitized
+
+
+def get_top_devices_metrics(agent_hosts=None, interval=30, limit=5):
+    """
+    Wrapper to fetch top devices' metrics.
+
+    :param agent_hosts: list of hostnames to filter (or None for all)
+    :param interval: interval in seconds for network rate calculation
+    :param limit: top N hosts per metric
+    :return: list of dicts representing metrics
+    """
+    metrics_objects = DevicesMetricsRepo.get_top_devices_metrics(
+        agent_hosts=agent_hosts,
+        interval_seconds=interval,
+        limit=limit
+    )
+
+    # Convert DevicesMetrics objects to dictionaries for JSON
+    metrics_list = [m.to_dict() for m in metrics_objects]
+
+    metrics_list = sanitize_metrics(metrics_list)
+    return metrics_list
Index: /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/system_metrics.py
===================================================================
--- /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/system_metrics.py	(revision 2706)
+++ /branches/amp_4_0/src/webui/webui/htdocs/new/src/hive/services/system_metrics.py	(working copy)
@@ -1,325 +1,64 @@
 from datetime import datetime, timedelta, timezone
-from tzlocal import get_localzone
 
-from hive.db.system_metrics_database import with_db_connection
-from hive.db.system_metrics_database import SystemMetrics, DiskMetrics, NetworkMetrics
-from hive.utils import andebug
+from hive.repositories.system_metrics import SystemMetricsRepo
 
 
-# ToDo: Add data access layer and reuse the db_client.
-# --- LATEST METRICS FUNCTIONS ---
-
-@with_db_connection
-def _get_latest_cpu_metrics(conn, host='AN'):
-    cur = conn.cursor()
-    # The query now directly calculates 100 - usage_idle
-    cpu_query = "SELECT time, host, 100 - usage_idle as cpu_percent FROM cpu WHERE time IN (SELECT max(time) FROM cpu WHERE host = %s) AND host = %s AND cpu = 'cpu-total' ORDER BY time DESC LIMIT 1;"
-    cur.execute(cpu_query, (host, host))
-    result = cur.fetchone()
-    cur.close()
-    if result:
-        time, host, cpu_percent = result
-        return SystemMetrics(time=time, host=host, cpu_percent=cpu_percent)
-    return None
-
-
-@with_db_connection
-def _get_latest_diskio_metrics(conn, host='AN'):
-    cur = conn.cursor()
-    disk_query = """
-                 SELECT
-                     bucket_time,
-                     ROUND(LEAST((SUM(io_time_total_ms) * 100.0 / 60000), 100), 2) AS disk_io_percent,
-                     ROUND(SUM(read_bytes_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS read_speed_bps,
-                     ROUND(SUM(write_bytes_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS write_speed_bps
-                 FROM (
-                          SELECT
-                              time_bucket('1 minute', time) AS bucket_time,
-                              GREATEST(io_time::BIGINT - LAG(io_time) OVER (PARTITION BY host ORDER BY time), 0) AS io_time_total_ms,
-                              GREATEST(read_bytes::BIGINT - LAG(read_bytes) OVER (PARTITION BY host ORDER BY time), 0) AS read_bytes_diff,
-                              GREATEST(write_bytes::BIGINT - LAG(write_bytes) OVER (PARTITION BY host ORDER BY time), 0) AS write_bytes_diff,
-                              EXTRACT(EPOCH FROM (time - LAG(time) OVER (PARTITION BY host ORDER BY time))) AS time_diff_sec
-                          FROM diskio
-                          WHERE host = %s
-                      ) sub
-                 WHERE io_time_total_ms IS NOT NULL
-                 GROUP BY bucket_time
-                 ORDER BY bucket_time DESC
-                 LIMIT 1;
-                 """
-    cur.execute(disk_query, (host,))
-    result = cur.fetchone()
-    cur.close()
-    if result:
-        time, disk_io_percent, read_speed, write_speed = result
-        return SystemMetrics(time=time, host=host, disk_io_percent=disk_io_percent, read_speed=read_speed,
-                             write_speed=write_speed)
-    return None
-
-
-@with_db_connection
-def _get_latest_mem_metrics(conn, host='AN'):
-    cur = conn.cursor()
-    # The query now directly selects used_percent
-    mem_query = "SELECT time, host, used_percent as mem_percent FROM mem WHERE time IN (SELECT max(time) FROM mem WHERE host = %s) AND host = %s ORDER BY time DESC LIMIT 1;"
-    cur.execute(mem_query, (host, host))
-    result = cur.fetchone()
-    cur.close()
-    if result:
-        time, host, mem_percent = result
-        return SystemMetrics(time=time, host=host, mem_percent=mem_percent)
-    return None
-
-
-@with_db_connection
-def _get_latest_disk_metrics(conn, host='AN'):
-    cur = conn.cursor()
-    disk_query = """
-                 SELECT time,
-                        host,
-                        device,
-                        path,
-                        total,
-                        used,
-                        free,
-                        used_percent
-                 FROM disk
-                 WHERE (host, device, time) IN (SELECT host,
-                                                       device,
-                                                       MAX(time)
-                                                FROM disk
-                                                WHERE host = %s
-                                                  AND path NOT LIKE 'tmpfs'
-                                                GROUP BY host, device)
-                 ORDER BY device ASC; \
-                 """
-
-    cur.execute(disk_query, (host,))
-    results = cur.fetchall()
-    cur.close()
-    metrics_list = []
-    for time, host, device, path, total, used, free, used_percent in results:
-        metrics_list.append(DiskMetrics(
-            time=time,
-            host=host,
-            device=device,
-            path=path,
-            total=total,
-            used=used,
-            free=free,
-            used_percent=used_percent
-        ))
-    return [m.to_dict() for m in metrics_list]
-
-
-@with_db_connection
-def _get_latest_net_metrics(conn, host='AN'):
-    cur = conn.cursor()
-    net_query = """
-                SELECT
-                    bucket_time,
-                    interface,
-                    ROUND(SUM(bytes_sent_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS bytes_sent_bps,
-                    ROUND(SUM(bytes_recv_diff) / GREATEST(1, SUM(time_diff_sec)), 2) AS bytes_recv_bps
-                FROM (
-                         SELECT
-                             time_bucket('1 minute', time) AS bucket_time,
-                             interface,
-                             GREATEST(bytes_sent::BIGINT - LAG(bytes_sent) OVER (PARTITION BY host, interface ORDER BY time), 0) AS bytes_sent_diff,
-                             GREATEST(bytes_recv::BIGINT - LAG(bytes_recv) OVER (PARTITION BY host, interface ORDER BY time), 0) AS bytes_recv_diff,
-                             EXTRACT(EPOCH FROM (time - LAG(time) OVER (PARTITION BY host, interface ORDER BY time))) AS time_diff_sec
-                         FROM net
-                         WHERE host = %s AND interface NOT LIKE 'lo' AND interface NOT LIKE 'all'
-                     ) sub
-                WHERE bytes_sent_diff IS NOT NULL
-                GROUP BY bucket_time, interface
-                ORDER BY bucket_time DESC
-                LIMIT 1;
-                """
-    cur.execute(net_query, (host,))
-    results = cur.fetchall()
-    cur.close()
-
-    metrics_list = []
-    for time, interface, bytes_sent, bytes_recv in results:
-        metrics_list.append(NetworkMetrics(
-            time=time,
-            host=host,
-            interface=interface,
-            bytes_sent_bps=bytes_sent,
-            bytes_recv_bps=bytes_recv
-        ))
-    return [m.to_dict() for m in metrics_list]
-
-
-def get_latest_system_metrics(host='AN'):
-    cpu_metrics = _get_latest_cpu_metrics(host=host)
-    mem_metrics = _get_latest_mem_metrics(host=host)
-    diskio_metrics = _get_latest_diskio_metrics(host=host)
-    disk_metrics = _get_latest_disk_metrics(host=host)
-    net_metrics = _get_latest_net_metrics(host=host)
+def get_latest_system_metrics():
+    cpu_metrics = SystemMetricsRepo.get_latest_cpu()
+    mem_metrics = SystemMetricsRepo.get_latest_memory()
+    disk_io_metrics = SystemMetricsRepo.get_latest_disk_io()
+    disk_metrics = SystemMetricsRepo.get_latest_disk_usage()
+    net_metrics = SystemMetricsRepo.get_latest_throughput()
     return {
         'cpu': cpu_metrics.to_dict() if cpu_metrics else None,
         'memory': mem_metrics.to_dict() if mem_metrics else None,
-        'diskio': diskio_metrics.to_dict() if diskio_metrics else None,
+        'disk_io': disk_io_metrics.to_dict() if disk_io_metrics else None,
         'disk_usage': disk_metrics,
         'net_metrics': net_metrics
     }
 
 
 # --- LAST 1HOUR METRICS FUNCTIONS ---
-@with_db_connection
-def _get_historical_cpu_metrics(conn, host='AN', hours=1):
-    cur = conn.cursor()
+def _get_historical_cpu_metrics(hours=1):
     now_utc_aware = datetime.now(timezone.utc)
     end_time = now_utc_aware.replace(tzinfo=None)
     start_time = end_time - timedelta(hours=hours)
     bucket_interval = '1 minute'
-    cpu_query = """
-                SELECT time_bucket(%s, time)        AS bucket_time,
-                       last(100 - usage_idle, time) AS cpu_usage
-                FROM cpu
-                WHERE time BETWEEN %s AND %s
-                  AND host = %s
-                  AND cpu = 'cpu-total'
-                GROUP BY bucket_time
-                ORDER BY bucket_time ASC; \
-                """
-    cur.execute(cpu_query, (bucket_interval, start_time, end_time, host))
-    results = cur.fetchall()
-    cur.close()
+    return SystemMetricsRepo.get_historical_cpu(bucket_interval, start_time, end_time)
 
-    metrics_list = []
-    for time_bucket, usage in results:
-        metrics_list.append(SystemMetrics(
-            time=time_bucket,
-            host=host,
-            cpu_percent=usage
-        ))
-    return [m.to_dict() for m in metrics_list]
 
-
-@with_db_connection
-def _get_historical_mem_metrics(conn, host='AN', hours=1):
-    cur = conn.cursor()
+def _get_historical_mem_metrics(hours=1):
     now_utc_aware = datetime.now(timezone.utc)
     end_time = now_utc_aware.replace(tzinfo=None)
     start_time = end_time - timedelta(hours=hours)
     bucket_interval = '1 minute'
-    mem_query = """
-                SELECT time_bucket(%s, time)    AS bucket_time,
-                       last(used_percent, time) AS mem_usage
-                FROM mem
-                WHERE time BETWEEN %s AND %s
-                  AND host = %s
-                GROUP BY bucket_time
-                ORDER BY bucket_time ASC; \
-                """
-    cur.execute(mem_query, (bucket_interval, start_time, end_time, host))
-    results = cur.fetchall()
-    cur.close()
+    return SystemMetricsRepo.get_historical_memory(bucket_interval, start_time, end_time)
 
-    metrics_list = []
-    for time_bucket, usage in results:
-        metrics_list.append(SystemMetrics(
-            time=time_bucket,
-            host=host,
-            mem_percent=usage
-        ))
-    return [m.to_dict() for m in metrics_list]
 
-
-@with_db_connection
-def _get_historical_diskio_metrics(conn, host='AN', hours=1):
-    cur = conn.cursor()
+def _get_historical_disk_io_metrics(hours=1):
     now_utc_aware = datetime.now(timezone.utc)
     end_time = now_utc_aware.replace(tzinfo=None)
     start_time = end_time - timedelta(hours=hours)
     bucket_interval = '1 minute'
-    diskio_query = """
-                   SELECT bucket_time,
-                          ROUND(LEAST((disk_io_total_ms * 100.0 / 60000), 100), 2) AS disk_io_percent
-                   FROM (SELECT time_bucket('1 minute', time)                            AS bucket_time,
-                                SUM(GREATEST(io_time::BIGINT - prev_io_time::BIGINT, 0)) AS disk_io_total_ms
-                         FROM (SELECT time,
-                                      io_time,
-                                      LAG(io_time) OVER (PARTITION BY host ORDER BY time) AS prev_io_time
-                               FROM diskio
-                               WHERE host = %s
-                                 AND time BETWEEN %s AND %s) sub
-                         WHERE prev_io_time IS NOT NULL
-                         GROUP BY bucket_time) final
-                   ORDER BY bucket_time ASC; \
-                   """
-    cur.execute(diskio_query, (host, start_time, end_time))
-    results = cur.fetchall()
-    cur.close()
+    return SystemMetricsRepo.get_historical_disk_io(bucket_interval, start_time, end_time)
 
-    metrics_list = []
-    for time_bucket, usage in results:
-        metrics_list.append(SystemMetrics(
-            time=time_bucket,
-            host=host,
-            disk_io_percent=usage
-        ))
-    return [m.to_dict() for m in metrics_list]
 
-
-@with_db_connection
-def _get_historical_net_metrics(conn, host='AN', hours=1):
-    cur = conn.cursor()
+def _get_historical_net_metrics(hours=1):
     now_utc_aware = datetime.now(timezone.utc)
     end_time = now_utc_aware.replace(tzinfo=None)
     start_time = end_time - timedelta(hours=hours)
     bucket_interval = '1 minute'
-    net_query = """
-                SELECT bucket_time,
-                       interface,
-                       ROUND(SUM(bytes_sent_diff) * 8 / GREATEST(1, SUM(time_diff_sec)),
-                             2)                                                                       AS bytes_sent_bps,
-                       ROUND(SUM(bytes_recv_diff) * 8 / GREATEST(1, SUM(time_diff_sec)), 2) AS bytes_recv_bps
-                FROM (SELECT time_bucket('1 minute', time)                                                            AS bucket_time,
-                             interface,
-                             GREATEST(bytes_sent::BIGINT -
-                                      LAG(bytes_sent) OVER (PARTITION BY host, interface ORDER BY time),
-                                      0)                                                                              AS bytes_sent_diff,
-                             GREATEST(bytes_recv::BIGINT -
-                                      LAG(bytes_recv) OVER (PARTITION BY host, interface ORDER BY time),
-                                      0)                                                                              AS bytes_recv_diff,
-                             EXTRACT(EPOCH FROM
-                                     (time - LAG(time) OVER (PARTITION BY host, interface ORDER BY time)))            AS time_diff_sec
-                      FROM net
-                      WHERE host = %s
-                        AND interface NOT LIKE 'lo' AND interface NOT LIKE 'all'
-                        AND time BETWEEN %s AND %s) sub
-                WHERE bytes_sent_diff IS NOT NULL
-                GROUP BY bucket_time, interface
-                ORDER BY bucket_time ASC; \
-                """
-    cur.execute(net_query, (host, start_time, end_time))
-    results = cur.fetchall()
-    cur.close()
+    return SystemMetricsRepo.get_historical_throughput(bucket_interval, start_time, end_time)
 
-    metrics_list = []
-    for time, interface, bytes_sent, bytes_recv in results:
-        metrics_list.append(NetworkMetrics(
-            time=time,
-            host=host,
-            interface=interface,
-            bytes_sent_bps=bytes_sent,
-            bytes_recv_bps=bytes_recv
-        ))
-    return [m.to_dict() for m in metrics_list]
 
-
-def get_historical_system_metrics(host='AN'):
-    cpu_metrics = _get_historical_cpu_metrics(host=host)
-    mem_metrics = _get_historical_mem_metrics(host=host)
-    diskio_metrics = _get_historical_diskio_metrics(host=host)
-    net_metrics = _get_historical_net_metrics(host=host)
+def get_historical_system_metrics():
+    cpu_metrics = _get_historical_cpu_metrics()
+    mem_metrics = _get_historical_mem_metrics()
+    disk_io_metrics = _get_historical_disk_io_metrics()
+    net_metrics = _get_historical_net_metrics()
     return {
         'cpu_history': cpu_metrics,
         'mem_history': mem_metrics,
-        'diskio_history': diskio_metrics,
+        'disk_io_history': disk_io_metrics,
         'net_history': net_metrics
     }
