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: add startAsyncCall support #418

Merged
merged 12 commits into from
Sep 8, 2022

Conversation

noahdietz
Copy link
Contributor

@noahdietz noahdietz commented Aug 23, 2022

Adds startAsyncCall to GapicClientTrait that initiates an API call via startApiCall, but directly returns the resulting Promise for the user to handle. Does not support Streaming RPCs today. To support async initialization of a PagedResponse, I added a getPagedListResponseAsync variant with all of the logic needed today, which is then called from the synchronous variant and waited upon.

Also moves all of the "call config" validation into a helper used by both startApiCall and startAsyncCall.

@noahdietz noahdietz requested review from a team as code owners August 23, 2022 21:27
@noahdietz noahdietz requested a review from bshaffer August 24, 2022 21:37
@noahdietz noahdietz requested a review from bshaffer August 29, 2022 18:31
Copy link
Contributor

@dwsupplee dwsupplee left a comment

Choose a reason for hiding this comment

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

LGTM, just a thought on the validation.

@noahdietz noahdietz requested a review from dwsupplee September 7, 2022 22:14
@bshaffer bshaffer merged commit fc90693 into googleapis:main Sep 8, 2022
@noahdietz noahdietz deleted the start-async-call branch September 8, 2022 14:47
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