Skip to content

Conversation

@rgehan
Copy link
Contributor

@rgehan rgehan commented Dec 8, 2025

Which issue does this PR close?

Closes #566

Rationale for this change

Currently, the only way to override the GCS base URL is to provide a service account credentials file that contains a gcs_base_url.

If for some reason the user cannot provide such a file (because they're authenticated a different way), being able to explicitly override the base URL is useful.

This can also be useful while testing locally, against a local implementation of GCS (I'm not personally doing this, but I suppose this is a valid use case)

What changes are included in this PR?

This PR adds a .with_base_url() method on the GCP builder, accompanied with unit tests.

This override takes precedence over the URL from the service account credentials file, but is optional, so this should be strictly compatible with the previous implementation.

Are there any user-facing changes?

New .with_base_url() on the GCS builder.

No breaking changes.

@rgehan rgehan changed the title Allow explicitly specify GCS base URL Allow explicitly specifying GCS base URL Dec 8, 2025
@rgehan rgehan marked this pull request as ready for review December 8, 2025 17:41
Copy link
Contributor

@tustvold tustvold left a comment

Choose a reason for hiding this comment

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

Thank you for this, I think we should probably add a config key to match this, otherwise looks good

@rgehan
Copy link
Contributor Author

rgehan commented Dec 12, 2025

@tustvold I've added a configuration key, and fixed lint/doc issues. Let me know if there's anything else I can do!

@tustvold tustvold merged commit de4a30e into apache:main Dec 13, 2025
8 checks passed
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.

Allow explicitly specifying the GCS base URL

3 participants