Application metrics of the API

Open
#717 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 7 days

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
45/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
docker, fastapi, grafana, prometheus, python

Research direction

Start by locating the API's existing Prometheus export and the PROMETHEUS_ENABLED setting, then read roadmap issue #25 and scenarios 10 and 11 to identify the required alerts. Configure Alloy to collect the selected error, duration, validation queue, and fail-open metrics. Done means the metrics are visible in Grafana and both alerts exist.

Written by the indexing model from the issue text.

Description

type: feat
Context & Objective

Part of the epic pyronear/roadmap#25 (Monitoring and alerting). The API has a Prometheus export, disabled today (PROMETHEUS_ENABLED=false). It would give the error rate, the request durations and the state of the validation queue.

What has to be done
  • Enable the export and choose the metrics: errors, durations, validation queue, sequences validated by fail-open (temporal model unreachable).
  • Collect them with Alloy and add the alerts of scenarios 10 and 11.
Done when
  • The metrics are visible in Grafana, and the two alerts exist
Dominant language
Python
Stars
31
Forks
15
Avg merge
7d 18h
Merged PRs (30d)
17

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from pyronear/pyro-api

All issues in pyronear/pyro-api

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.