Skip to content

Commit

Permalink
use container_spec_memory_limit_bytes as container memory limit met…
Browse files Browse the repository at this point in the history
…ric source
  • Loading branch information
chengjoey committed Feb 21, 2024
1 parent daf01c2 commit 8348115
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func (p *provider) getCpuLineGraph(ctx context.Context, startTime, endTime int64
}

func (p *provider) getMemoryLineGraph(ctx context.Context, startTime, endTime int64, instanceId string) ([]*model.LineGraphMetaData, error) {
statement := fmt.Sprintf("SELECT round_float(avg(mem_limit::field), 2),round_float(avg(mem_usage::field), 2) " +
statement := fmt.Sprintf("SELECT round_float(avg(container_spec_memory_limit_bytes::field), 2),round_float(avg(mem_usage::field), 2) " +
"FROM docker_container_summary " +
"WHERE pod_uid::tag=$pod_uid " +
"GROUP BY time()")
Expand Down

0 comments on commit 8348115

Please sign in to comment.