You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Pubsub API redesign broke support for PUBSUB_EMULATOR_HOST #3886
changed the title [-]Pubsub API redesign doesn't support PUBSUB_EMULATOR_HOST[/-][+]Pubsub API redesign broke support for PUBSUB_EMULATOR_HOST[/+]on Aug 27, 2017
I admit unfamiliarity with the Pub/Sub emulator. I will look into what I need to do to make this work for you. If it is just an alternative hostname, that will work, but the incantation is slightly different.
@lukesneeringer Should just be the hostname I would think (maybe https cert checking and the like as well, unsure what the actual code path looks like)
Seems worthwhile to add some sort of acceptance tests for this?
We previously did not have any CI testing for the emulator integration, but now that we control the Docker image for CircleCI, it would be very easy to add the gcloud SDK (where the emulators live) to the Docker image. Yay!
@lukesneeringer & @dhermes Is there an ETA for a fix? The workaround with the **kwargs doesn't work since there's still some https stuff failing alongside it...
@lukesneeringer Let's chat about this. I had great support for Pub/Sub, Bigtable and Datastore, but it got nuked when we switched from tox to nox.
Thank you for your work on emulator support, however for Pub/Sub there was a noticeable drawback, which was that the client library required any valid GCP service account credentials before it would proceed to use the emulator. Hopefully the replaced emulator support won't have this drawback and will use the emulator without credentials, as e.g. the Datastore client does.
Hi team, is this issue on the work schedule at all? This part of our system needs some refactoring and I'm trying to work out if we should delay so we can upgrade to the new client. Thanks.
Reacted by Julien Singler, Jorrit Posthuma and Suhaas Prasad
According to Google documentation the developer (users of the library) should not have to do anything in code to use the emulator. Only set the proper environment variable. Also that is the way it worked before this ticket (apparently).
There are two things missing IMHO: 1) a test case that checks that when the PUBSUB_EMULATOR_HOST is set all requests to PUBSUB are forwarded there, and 2) support inside both the subscriber and the publisher to set service_path and service_port accordingly at runtime without user intervention.
Also as per @suhaasprasad comment, the client should allow for non-SSL connections when honouring the EMULATOR variable.
Activity
[-]Pubsub API redesign doesn't support PUBSUB_EMULATOR_HOST[/-][+]Pubsub API redesign broke support for PUBSUB_EMULATOR_HOST[/+]lukesneeringer commentedon Aug 28, 2017
Hi @bpicolo,
Thanks for letting me know.
I admit unfamiliarity with the Pub/Sub emulator. I will look into what I need to do to make this work for you. If it is just an alternative hostname, that will work, but the incantation is slightly different.
dhermes commentedon Aug 28, 2017
@lukesneeringer Let's chat about this. I had great support for Pub/Sub, Bigtable and Datastore, but it got nuked when we switched from
toxtonox.bpicolo commentedon Aug 28, 2017
@lukesneeringer Should just be the hostname I would think (maybe https cert checking and the like as well, unsure what the actual code path looks like)
Seems worthwhile to add some sort of acceptance tests for this?
lukesneeringer commentedon Aug 28, 2017
@bpicolo Probably.:-)
If it is just hostname, you can send the
service_pathkeyword argument to the client (it gets passed to that object if added in**kwargshere.dhermes commentedon Aug 28, 2017
We previously did not have any CI testing for the emulator integration, but now that we control the Docker image for CircleCI, it would be very easy to add the
gcloudSDK (where the emulators live) to the Docker image. Yay!hannesholst commentedon Aug 29, 2017
@lukesneeringer & @dhermes Is there an ETA for a fix? The workaround with the **kwargs doesn't work since there's still some https stuff failing alongside it...
wscheep commentedon Sep 4, 2017
Same problem here, hoping for a quick fix as we're using the emulator to test most of our services..
cgthayer commentedon Sep 18, 2017
:-( uhhh, how were the API changes tested before the release if the emulator broke #test-in-prod
robhaswell commentedon Sep 21, 2017
(This issue is a blocker for me deploying this wonderful new client 😢)
@dhermes
Thank you for your work on emulator support, however for Pub/Sub there was a noticeable drawback, which was that the client library required any valid GCP service account credentials before it would proceed to use the emulator. Hopefully the replaced emulator support won't have this drawback and will use the emulator without credentials, as e.g. the Datastore client does.
robhaswell commentedon Oct 6, 2017
Hi team, is this issue on the work schedule at all? This part of our system needs some refactoring and I'm trying to work out if we should delay so we can upgrade to the new client. Thanks.
suhaasprasad commentedon Oct 25, 2017
Any workaround here? Passing in the service_path and service_port to the client doesn't seem to work and prints the following error:
E1025 00:04:54.085080000 140737010254784 ssl_transport_security.c:940] Handshake failed with fatal error SSL_ERROR_SSL: error:100000f7:SSL routines:OPENSSL_internal:WRONG_VERSION_NUMBER.marcfargas commentedon Oct 25, 2017
Hi,
According to Google documentation the developer (users of the library) should not have to do anything in code to use the emulator. Only set the proper environment variable. Also that is the way it worked before this ticket (apparently).
There are two things missing IMHO: 1) a test case that checks that when the PUBSUB_EMULATOR_HOST is set all requests to PUBSUB are forwarded there, and 2) support inside both the subscriber and the publisher to set service_path and service_port accordingly at runtime without user intervention.
Also as per @suhaasprasad comment, the client should allow for non-SSL connections when honouring the EMULATOR variable.
Am I missing something?
marcfargas commentedon Oct 25, 2017
Temporary workaround (ugly) solves the SSL problem:
suhaasprasad commentedon Oct 25, 2017
I'm still unclear as to the root issue, but I've reverted to using version 0.27.0 of the google-cloud-pubsub library for now.
lukesneeringer commentedon Oct 30, 2017
I just merged a fix for this; release should be soon (sometime this week, hopefully in the early half).
robhaswell commentedon Oct 30, 2017
Amazing, thanks @lukesneeringer.