feat(metrics): Instrument commits and emit CommitReport ( #1236) - #1596
Open
tanmayrauth wants to merge 2 commits into
Open
feat(metrics): Instrument commits and emit CommitReport ( #1236)#1596tanmayrauth wants to merge 2 commits into
tanmayrauth wants to merge 2 commits into
Conversation
Fifth PR of the metrics reporting framework. Emits a CommitReport from the commit path on successful completion: - the retry loop in doCommit now records the total duration and the number of attempts; - the committed snapshot's summary is mapped into a CommitReport, under Java's commit-report metric names. iceberg-go's summary keys differ from those names (e.g. added-files-size -> added-files-size-bytes, deleted-data-files -> removed-data-files, added-position-deletes -> added-positional-deletes); the mapping translates them so the wire format matches Java. Metrics with no iceberg-go summary key (DVs, manifest counts) are omitted rather than reported as zero. The committed table now also preserves its reporter. With the default no-op reporter this is a pure no-op for existing users.
Java's CommitReport carries a metadata map (engine/commit context) that iceberg-go does not thread into the commit path yet. Mark it as a TODO in buildCommitReport rather than emitting an empty map.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Emits a spec-compliant CommitReport from the commit path on successful completion:
added-files-size-bytes, deleted-data-files → removed-data-files, added-position-deletes → added-positional-deletes, …) so the wire format matches Java and dashboards line up across implementations.
Behavior notes
commitAddedSnapshot.
Deferred
CommitReport.Metadata (Java's engine/commit-context map) is left unset with a TODO — iceberg-go doesn't thread that context into the commit path yet; a follow-up will populate it.
Testing
Realted to #1236