cosmo icon indicating copy to clipboard operation
cosmo copied to clipboard

Add planning stage in metrics

Open biubiubiuboomboomboom opened this issue 5 months ago • 5 comments

Component(s)

router

Is your feature request related to a problem? Please describe.

Currently , the time spent in the planning stage is only available in traces , but alerts and dashboards cannot be built from trace data to monitor it .

Describe the solution you'd like

Maybe we could add the time spent in the planning stage to metrics.

Describe alternatives you've considered

No response

Additional context

No response

biubiubiuboomboomboom avatar Jul 03 '25 10:07 biubiubiuboomboomboom

WunderGraph commits fully to Open Source and we want to make sure that we can help you as fast as possible. The roadmap is driven by our customers and we have to prioritize issues that are important to them. You can influence the priority by becoming a customer. Please contact us here.

github-actions[bot] avatar Jul 03 '25 10:07 github-actions[bot]

Hi @biubiubiuboomboomboom, we do have a metric for operation planning time, see here: https://cosmo-docs.wundergraph.com/router/metrics-and-monitoring/prometheus-metric-reference#router-graphql-operation-planning-time

Would that work for your use case?

endigma avatar Jul 08 '25 09:07 endigma

Yes, this is very useful to me. However, this metric represents the total planning time and cannot distinguish the situation of each phase.

biubiubiuboomboomboom avatar Aug 06 '25 09:08 biubiubiuboomboomboom

Hi, can you explain your use case for this and what specifically you'd want to measure?

endigma avatar Aug 06 '25 09:08 endigma

Sure. I hope to build a dashboard in Grafana to monitor the entire lifecycle of a request—starting from when it is received, through each processing phase in Cosmo, and track the time taken for each phase. This way, I can identify anomalies when there are abnormal fluctuations in latency.

biubiubiuboomboomboom avatar Aug 06 '25 10:08 biubiubiuboomboomboom