Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Clients should support the universe domain option #1365

Open
wants to merge 17 commits into
base: main
Choose a base branch
from

Conversation

danieljbruce
Copy link
Contributor

@danieljbruce danieljbruce commented Jan 22, 2025

Summary:

The user should be able to set the universe domain so that outgoing calls work with a different Google Cloud Universe. Right now, if the user specifies a universe domain then it will not get used and the request will just be sent to the default Datastore endpoint.

Analogous changes were made in googleapis/nodejs-bigtable#1563.

Changes:

src/index.ts: If a custom domain isn't provided and a universe domain is provided then instead of using the default url the client will send requests to a url for the universe domain.

test/service-path.ts: Add tests for when user provides a universe domain or uses the universe domain environment variable.

test/gapic-mocks/get-initialized-datastore-client.ts: A change to the test infrastructure that allows us to create a more realistic initialized Datastore client with a custom set of Datastore options.

test/request.ts: The linter is now complaining about this file so a cast is needed.

@danieljbruce danieljbruce requested review from a team as code owners January 22, 2025 18:58
@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: datastore Issues related to the googleapis/nodejs-datastore API. labels Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: datastore Issues related to the googleapis/nodejs-datastore API. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant