Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions internal/assets/dashboard/metric_en_US.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -722,6 +722,38 @@ OBCLUSTER_OVERVIEW:
name: wait_time
unit: us
name: Waiting for event time
OBPROXY_OVERVIEW:
- name: OBProxy overview metrics
description: Obproxy overview metrics
metricGroups:
- name: TPS
description: transaction count per second
metrics:
- name: total
description: transaction count per second
key: transaction_total
unit:
- name: QPS
description: request count per second
metrics:
- name: total
description: request count per second
key: request_total
unit:
- name: Connections
description: obproxy connections
metrics:
- name: connections
description: connections
key: current_session
unit:
- name: SQL response time
description: average response time per SQL query
metrics:
- name: response_time
description: average elapsed time for request
key: request_cost
unit: "μs"
OBPROXY:
- name: OBProxy service monitoring
description: Obproxy service monitoring
Expand Down
34 changes: 33 additions & 1 deletion internal/assets/dashboard/metric_zh_CN.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -739,7 +739,39 @@ OBCLUSTER_OVERVIEW:
key: wait_event_rt
name: wait_time
unit: "\u03BCs"
name: "\u7B49\u5F85\u4E8B\u4EF6\u8017\u65F6"
name: "等待事件耗时"
OBPROXY_OVERVIEW:
- name: OBProxy 概览指标
description: OBProxy 概览指标
metricGroups:
- name: TPS
description: 每秒事务数
metrics:
- name: total
description: 每秒事务数
key: transaction_total
unit:
- name: QPS
description: 每秒请求数
metrics:
- name: total
description: 每秒请求数
key: request_total
unit:
- name: 连接数
description: OBProxy 连接数
metrics:
- name: connections
description: 连接数
key: current_session
unit:
- name: SQL 响应时间
description: 平均每条 SQL 响应时间
metrics:
- name: response_time
description: 平均每次请求耗时
key: request_cost
unit: "μs"
OBPROXY:
- name: OBProxy 服务监控
description: OBProxy 服务监控
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ const (
ScopeTenantOverview = "OBTENANT_OVERVIEW"
ScopeTenant = "OBTENANT"
ScopeOBProxy = "OBPROXY"
ScopeOBProxyOverview = "OBPROXY_OVERVIEW"
)

const (
Expand Down
3 changes: 2 additions & 1 deletion internal/dashboard/handler/metric_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ func ListMetricMetas(c *gin.Context) ([]response.MetricClass, error) {
metricconst.ScopeTenant,
metricconst.ScopeClusterOverview,
metricconst.ScopeTenantOverview,
metricconst.ScopeOBProxy:
metricconst.ScopeOBProxy,
metricconst.ScopeOBProxyOverview:
default:
return nil, httpErr.NewBadRequest("invalid scope")
}
Expand Down