prometheus_client_php icon indicating copy to clipboard operation
prometheus_client_php copied to clipboard

High memory usage for generate metrics

Open Enotze opened this issue 8 months ago • 0 comments

Use promphp/prometheus_client_php version 2.7.1 and APCng

I am use histograms with name 'sdui_component_time_generation_bucket' and labels 'component', 'state_id' image Components count is 100 State_id count is 100 Total number of variants 100 * 100 = 10 000 Generated ~ 128 777 rows for histograms image And for response with 15.1 MB image

PHP use 156 MB image

I think it is because all metrics collect to one array \Prometheus\Storage\APCng::collect image

And all samples in one array \Prometheus\Storage\APCng::collectHistograms image

I think solution it is use php generator

Enotze avatar Oct 18 '23 09:10 Enotze