Repository navigation
refactor(io)!: hide gocloud types in blobfs and gcs behind interfaces - #2635
Open
laskoviymishka wants to merge 3 commits into
Open
laskoviymishka wants to merge 3 commits into
laskoviymishka wants to merge 3 commits into
Conversation
blobfs.New returned a struct embedding *blob.Bucket, so every gocloud bucket method was part of our API. The struct is now unexported and New returns a FileIO interface made of the iceberg-go io interfaces it already implemented, plus io.Closer so callers can still close the bucket. The struct keeps embedding *blob.Bucket, as agreed on the issue. NewWriter and Writer exposed *blob.WriterOptions and *blob.Writer and gcs.ParseGCSConfig returned *gcsblob.Options. None had callers outside their package, so they are unexported. blobfs.New still takes a *blob.Bucket on purpose. No behavior change. The hadoop catalog assertion and the azure and rest tests now use the interface, and releases.md gets a compatibility note. Part of apache#2062. Signed-off-by: laskoviymishka <laskoviymishka@gmail.com>
Signed-off-by: laskoviymishka <laskoviymishka@gmail.com>
laskoviymishka
marked this pull request as ready for review
November 18, 2026 13:36
Signed-off-by: laskoviymishka <laskoviymishka@gmail.com>
This branch has not been deployed
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.
blobfs.Newnow returns ablobfs.FileIOinterface instead of a struct embedding*blob.Bucket, so gocloud methods are no longer reachable from the return value. The interface lists the iceberg-go io interfaces the struct already implemented, plusio.Closer, since callers and the REST catalog close the IO. The struct is unexported and still embeds the bucket, following the shape on the issue.NewWriter,Writerandgcs.ParseGCSConfigexposed gocloud types and had no outside callers, so they are unexported too.blobfs.Newstill takes a*blob.Bucket; that stays as is.There is no behavior change and no new tests. The compile-time assertions in blobfs and the hadoop catalog cover the new interface, and the azure and REST tests were moved to it. apidiff on blobfs and gcs reports only the
FileIO/Newtype change and the removal ofWriterandParseGCSConfig. A compatibility note is added to releases.md.Part of #2062.