Skip to content

Commit

Permalink
fix: Get the query parameter pass of the online number interface chan…
Browse files Browse the repository at this point in the history
…ge (#1361)

Co-authored-by: husq <[email protected]>
  • Loading branch information
HuSQ123 and husq authored Jul 10, 2024
1 parent 0e8091f commit 2459aec
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/components/CustomChart/rangeChart.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,13 +124,13 @@ export default class RangeChart extends PureComponent {
const parameter = isState ? serviceAlias : serviceId;
switch (T) {
case 'containerMem':
return `sum(container_memory_rss{name=~".*${groupName}-${serviceCname}.*"}/1024/1024) by (pod, namespace)`;
return `sum(container_memory_rss{pod=~".*${groupName}-${serviceCname}.*"}/1024/1024) by (pod, namespace)`;
case 'containerCpu':
return `sum(irate(container_cpu_usage_seconds_total{name=~".*${groupName}-${serviceCname}.*"}[5m])*100)by(pod,namespace)`;
return `sum(irate(container_cpu_usage_seconds_total{pod=~".*${groupName}-${serviceCname}.*"}[5m])*100)by(pod,namespace)`;
case 'containerNetR':
return `rate(container_network_receive_bytes_total{name=~".*${groupName}-${serviceCname}.*"}[1m])/1024`;
return `rate(container_network_receive_bytes_total{pod=~".*${groupName}-${serviceCname}.*"}[1m])/1024`;
case 'containerNetT':
return `rate(container_network_transmit_bytes_total{name=~".*${groupName}-${serviceCname}.*"}[1m])/1024`;
return `rate(container_network_transmit_bytes_total{pod=~".*${groupName}-${serviceCname}.*"}[1m])/1024`;

case 'responseTime':
return `ceil(avg(app_requesttime{mode="avg",service_id="${serviceId}"}))`;
Expand Down

0 comments on commit 2459aec

Please sign in to comment.