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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Use REST #1698
feat: Use REST #1698
Conversation
@schmidt-sebastian this is cool, is your intention to default to gRPC, and document REST? |
@bcoe I haven't decided yet. We need to fix one more issue with queries and then compare performance data to see what mode should be the default. |
e7fbac8
to
3226ee9
Compare
3226ee9
to
6166aa3
Compare
6166aa3
to
4767a64
Compare
@MarkDuckworth It works now! When I Note: I'm using the pre-released version of The main change is in the client factory here: https://github.com/googleapis/nodejs-firestore/pull/1698/files#diff-33330e7a0daf2387ffc6f936c4d6cb4dd23b4b404446a5e34d2cab779e47cb50R552 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! One minor suggestion but I don't feel very strongly about it.
status.message || undefined | ||
); | ||
const error = | ||
new (require('google-gax/build/src/fallback').GoogleError)( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm wondering if instead of using this path to fallback, we can use a subpath export to the fallback? https://nodejs.org/api/packages.html#subpath-exports
Maybe it's already set up that way, I didn't look at gax source yet. But the path indicates maybe it is not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a great idea (and "today I learned" as well).
We will be able to safely start using it when we drop Node 12 support. The documentation says subpath exports were added in v12.7.0 but we have "engines.node"
set to ">=12"
now, so we cannot possibly start using it without making a semver major. But for the next major I definitely want to do it. I filed googleapis/gax-nodejs#1337 so that we don't forget.
Hello! Sorry for reviving an old pull request, but was this data published anywhere?
|
Performance data was not published. From what I have seen, internal tests and customer reports indicate a speedup when using preferRest in the cold start of functions. However, I cannot give specific numbers. We did not change the default mode, which is still gRPC. |
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #<issue_number_goes_here> 馃