prometheus-community / prometheus-community/stackdriver_exporter
google.projects.filter is only evaluated once at startup — new/removed child projects aren't picked up without a restart
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 295
- Forks
- 117
- Avg merge
- 9d 14h
- Merged PRs (30d)
- 7
Description
What happened
When using google.projects.filter to dynamically discover projects (e.g.
all child projects under an org/folder matching a label), the exporter only
evaluates that filter once, at startup. If a new child project is added
later (or an existing one is removed), the exporter keeps scraping the
original, stale project list — the only way to pick up the change is to
restart the pod.
This defeats the purpose of using a filter for dynamic discovery, especially
in Kubernetes, where pods run for long periods without restarting.
Expected behavior
Newly added (or removed) child projects matching google.projects.filter
should be picked up within a reasonable time, without requiring a restart.
I'm working on a fix for this and plan to submit a PR within the next couple of days.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No files or tests are named. Start by locating where google.projects.filter is evaluated at exporter startup and how that project list is used for scraping; then verify that adding or removing a matching child project is reflected without a restart.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, google-cloud, prometheus
- Domain
- cloud, observability-sre
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100