-
Notifications
You must be signed in to change notification settings - Fork 18
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
Swap from wrapped Client to pure gRPC Client #4
Comments
unfortunately I don't have any permissions anymore to access the repo.
Could you please grant access to me and my team-mate Slavey (@slaff)?
Thanks.
Zhouyihai Ding <[email protected]> schrieb am Di., 30. Jan. 2018 um
02:24 Uhr:
… Assigned #4 <#4>
to @burkl <https://github.com/burkl>.
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub
<#4 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AALCVp6cenWQ8LjNngu13lHdI9Mo292pks5tPm9CgaJpZM4RxniJ>
.
|
Granted. |
I'll try remove you from the "collaborators" and re-send the invitation again. |
I've opened a pull request which allows you to merge with the composer files. In the example code we're relying on ./vendor/google/cloud-firestore/V1beta1/FirestoreClient.php which is generated from a proto file and has the same content as the file you've mentioned in 1. Why do you recommend to generate the files on your own? I expect to get the same content as it is distributed with packagist/composer? |
It's not exact the same. |
I am not sure where |
@ZhouyihaiDing I tried to follow your instructions but I am facing multiple issues. So let me briefly explain what I did and where are the issues:
And then tried to compile the api, as recommended.
During the compilation I was faced with the following issues:
I had to edit some files but then was faced with the final issue, that I do not know how to solve:
So my question is what I am doing wrong? Is there a version of |
Hi @slaff ,
# Install protoc from protobuf:
# install grpc_[language]_plugin from grpc:
# Generate pb files:
|
Implemented in PR #6 |
The FirestoreClient you use is download from Google Cloud by composer, which actually is wrapper around gRPC. This API is designed to face the customers, with some gRPC parameters unseen by the user.
However, we want to test the gRPC features with this tests, which means the Client should be pure gRPC Client generated directly from proto files. The only thing needed to be downloaded by composer is auth API..
There are 2 ways to changing your current wrapper Client to pure gRPC Client, which I recommend 2:
use the FirestoreClient under
vendor/google/proto-client/src/Google/Cloud/Firestore/V1beta1/FirestoreGrpcClient.php
Generate FirestoreClient by your own.
For example, my way to generate pb files:
Then change your current Client to the one in
~/grpc-gcp-php/firestore/examples/end2end/src/Google/Cloud/Firestore/V1beta1/FirestoreClient.php
,and then set the credentials with it.
I also have a related example of creating pure Logging gRPC client for you as reference.
The text was updated successfully, but these errors were encountered: