Skip to content

feat: add MetricsBuckets type and BucketAPIMetrics for per-bucket monitoring#590

Open
0xMALVEE wants to merge 1 commit intominio:mainfrom
0xMALVEE:feat/bucket-metrics
Open

feat: add MetricsBuckets type and BucketAPIMetrics for per-bucket monitoring#590
0xMALVEE wants to merge 1 commit intominio:mainfrom
0xMALVEE:feat/bucket-metrics

Conversation

@0xMALVEE
Copy link
Copy Markdown
Contributor

@0xMALVEE 0xMALVEE commented May 6, 2026

feat: add MetricsBuckets type and BucketAPIMetrics for per-bucket monitoring

required for pr: https://github.com/miniohq/eos/pull/4877

@0xMALVEE 0xMALVEE force-pushed the feat/bucket-metrics branch from e14c90d to a90be41 Compare May 6, 2026 16:33
Comment thread metrics.go Outdated
Comment thread metrics.go Outdated
@0xMALVEE 0xMALVEE force-pushed the feat/bucket-metrics branch 3 times, most recently from ed5e7b3 to 442ad33 Compare May 7, 2026 16:47
@0xMALVEE 0xMALVEE requested a review from klauspost May 8, 2026 07:20
Comment thread metrics.go Outdated
Comment thread metrics.go Outdated
Comment thread metrics.go Outdated
Comment thread metrics.go Outdated
Comment thread metrics.go Outdated
Comment thread metrics.go Outdated
@0xMALVEE 0xMALVEE force-pushed the feat/bucket-metrics branch 2 times, most recently from 5042247 to 698cb50 Compare May 8, 2026 08:56
@0xMALVEE 0xMALVEE requested a review from klauspost May 8, 2026 08:58
Comment thread metrics.go Outdated
@0xMALVEE 0xMALVEE force-pushed the feat/bucket-metrics branch from 698cb50 to 139bb96 Compare May 8, 2026 09:20
@0xMALVEE 0xMALVEE requested a review from klauspost May 8, 2026 09:22
@0xMALVEE 0xMALVEE force-pushed the feat/bucket-metrics branch from 139bb96 to 9ab2917 Compare May 8, 2026 10:00
@0xMALVEE
Copy link
Copy Markdown
Contributor Author

0xMALVEE commented May 8, 2026

@klauspost take a look

Copy link
Copy Markdown
Contributor

@klauspost klauspost left a comment

Choose a reason for hiding this comment

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

lgtm! Gives valuable data for multiple use cases and should still be reasonably sized - as well as give good caller flexibility.

Add BucketMetrics, BucketWindowMetrics, and BucketAPIMetrics types for
tracking per-bucket S3 request counts, byte I/O, and time-series
history across minute/hour/day windows.

- BucketMetrics holds per-operation totals, byte counters (BytesIn,
  BytesOut), and time-series for one bucket in one time window
- BucketWindowMetrics aggregates BucketMetrics across nodes with an N
  counter and metadata (interval, first-time); Merge right-aligns
  time-series slices so the most-recent slot always lines up
- BucketAPIMetrics carries three independent windows (LastMinute,
  LastHour, LastDay) populated based on requested MetricFlags
- Add Buckets []string to MetricsOptions for per-bucket filtering,
  encoded as a comma-separated ?buckets= query parameter
- Regenerate metrics_gen.go
@0xMALVEE 0xMALVEE force-pushed the feat/bucket-metrics branch from 9ab2917 to 174bda1 Compare May 8, 2026 12:47
@0xMALVEE 0xMALVEE requested a review from harshavardhana May 8, 2026 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants