Skip to content
This repository was archived by the owner on Oct 7, 2025. It is now read-only.

vacuum_interval for prometheus Export - #85

Merged
ynHuber merged 2 commits into
BelWue:masterfrom
ynHuber:issue_80_vacuum_parameter
Feb 3, 2025
Merged

ynHuber merged 2 commits into
BelWue:masterfrom
ynHuber:issue_80_vacuum_parameter

Conversation

@ynHuber

@ynHuber ynHuber commented Nov 22, 2024 •

Copy link
Copy Markdown
Collaborator

Added a parameter that defines a fixed intervall at which all prometheus exporter counters are getting reset
Fixes #80

Added a parameter that defines a fixed intervall at which all prometheus exporter counters are getting reset
MetricsPath string // optional, default is "/metrics"
FlowdataPath string // optional, default is "/flowdata"
Labels []string // optional, list of labels to be exported
VacuumInterval *time.Duration // optional, intervall in which counters should be reset

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should add some emphasis and warning that vacuuming might happen at an inconvenient time which leads to some data loss (at most about one scrape interval's worth).

I believe it might be possible to hook the next Gather operation and only vacuum then, which would prevent most of the possible data loss 🤔

@ynHuber ynHuber mentioned this pull request Jan 29, 2025
ynHuber added a commit that referenced this pull request Feb 3, 2025
New Major Version v2

### Maintenance
- Moved GitHub orgs from bwNetFlow to BelWue @9er  #89
- Upgraded golang version to 1.23.2

### Bug fixes
- waitgroup in lumberjack segment. (@JustKiddingCode #79)
-  vacuum_interval for prometheus Export (@ynHuber #85)

### New segments
- diskbuffer (@JustKiddingCode #78)
- mongodb (@ynHuber #81)

### Breaking Changes:
- Protobuffer upgrade to match changes [introduced  in goflow2 v2.2.1](netsampler/goflow2@3326554) (@ynHuber  #86)
@ynHuber
ynHuber merged commit 1b396ae into BelWue:master Feb 3, 2025
@ynHuber
ynHuber deleted the issue_80_vacuum_parameter branch September 17, 2025 08:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

export/prometheus: metrics growing indefinitly, causing timeouts

2 participants

⌂ 换网址