Skip to content

feat(inkless): add partition fan-in commit metrics#675

Merged
viktorsomogyi merged 1 commit into
mainfrom
jeqo/kc-290-commit-fan-in-metrics
Jun 30, 2026
Merged

feat(inkless): add partition fan-in commit metrics#675
viktorsomogyi merged 1 commit into
mainfrom
jeqo/kc-290-commit-fan-in-metrics

Conversation

@jeqo

@jeqo jeqo commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Adds two per-broker histograms on FileCommitter: PartitionsPerCommit (distinct topic-partitions in a committed file) and BatchesPerPartitionPerCommit (a partition's batch fan-in). Batches-per-partition is the workload dimension that drives batch coalescing, so it surfaces the per-partition coalescing opportunity.

Computed in a single linear pass over the committed requests, which are already grouped by topic-partition (BatchBuffer.close sorts them) — no intermediate grouping map. Regenerates metrics.rst.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds new FileCommitter commit “fan-in” observability by tracking (1) how many distinct topic-partitions appear in a committed file and (2) how many batches each partition contributes, helping quantify batch coalescing opportunity.

Changes:

  • Add two new per-broker histograms to FileCommitterMetrics: PartitionsPerCommit and BatchesPerPartitionPerCommit.
  • Record the new metrics during FileCommitter.commit(...) using a single linear pass over already partition-grouped requests.
  • Add unit tests for the new histograms and regenerate docs/inkless/metrics.rst.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
storage/inkless/src/main/java/io/aiven/inkless/produce/FileCommitterMetrics.java Introduces two new histograms and computes partition fan-in from grouped commit requests.
storage/inkless/src/main/java/io/aiven/inkless/produce/FileCommitter.java Records the new fan-in metrics when a file is successfully committed.
storage/inkless/src/test/java/io/aiven/inkless/produce/FileCommitterMetricsTest.java Adds focused tests validating fan-in counting behavior and accumulation across commits.
docs/inkless/metrics.rst Documents the two new FileCommitter metrics in the metrics reference.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jeqo jeqo marked this pull request as ready for review June 29, 2026 19:52
Adds two per-broker histograms on FileCommitter: PartitionsPerCommit (distinct
topic-partitions in a committed file) and BatchesPerPartitionPerCommit (a
partition's batch fan-in). Batches-per-partition is the workload dimension that
drives batch coalescing, so it surfaces the per-partition coalescing opportunity.

Computed in a single linear pass over the committed requests, which are already
grouped by topic-partition (BatchBuffer.close sorts them) — no intermediate
grouping map. Regenerates metrics.rst.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@jeqo jeqo force-pushed the jeqo/kc-290-commit-fan-in-metrics branch from 7a7b359 to df85d10 Compare June 30, 2026 06:40
@jeqo jeqo requested a review from viktorsomogyi June 30, 2026 11:41
@viktorsomogyi viktorsomogyi merged commit 97b7f49 into main Jun 30, 2026
4 checks passed
@viktorsomogyi viktorsomogyi deleted the jeqo/kc-290-commit-fan-in-metrics branch June 30, 2026 12:09
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.

3 participants