prometheus / prometheus/client_python

Set label-specific timestamps

Open
#917 2 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
4.4k
Forks
876
Avg merge
8d 4h
Merged PRs (30d)
1

Description

Issue #588 describes a way to set a timestamp for a whole metric using a custom collector. However, this solution does not work if different timestamps for different labels are required (e.g. a metric temperature with label source=node1 and source=node2) a more specific setting is described here and additional reasoning for this feature can be found here.

As issue #588 is closed and does not seem to get much attention anymore I decided to create a new issue for this more specific use case.

Contributor guide

Open the contributing guide

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.

Research direction

Start by reading issue #588 and the two linked comments, which describe the existing custom-collector approach and the requested label-specific behavior. Define what support for distinct timestamps on each label set should look like and verify it against the temperature example.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
observability-sre
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.