-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
GCD 0.1.7 release incompatible with v1beta3 emulator #117
Comments
Looks like it's calling @ajkannan What's the correct way to configure gcloud-java to talk to the local emulator? |
By the way, thank you for providing code for the repro! |
@eddavisson, this looks like a problem of conflicting constraints in the v1beta3 client. When specifying a localhost, scheme is not allowed. As a result, @tom-haines Thanks for pointing this out and providing repro code! I would like to make a suggestion if you are using code similar to your repro code to set up your own tests. |
I think the issue might be that The "local host" option is a little awkward, but it provides an additional hint to our client not to try to get credentials from the local environment (which can be slow). A couple of options come to mind off the top of my head:
|
When a user sets the host to "127.0.0.1:8000", To clarify what I was saying before, it's not possible to supply raw IP addresses to the local host option in this library because |
Fixed in 1.0.0-beta.2. |
when will v1.0.0 released? |
Hi @email2liyang, are you referring to v1.0.0 for the I just made a pull request to update |
Thanks @ajkannan for the prompt fix (and note your PR has now been merged into gcloud-java). Regarding whether this is a blocker re use of hostnames: I don't think you can use hostnames as suggested, and hence remains a blocker for using v0.1.7 with the current emulator. In regression repo, have a look at the last test (copied here): Even when using a hostname with the emulator (here hardwired hostname "docker-host" to
Will FAIL. But will PASS under 0.1.6
example config:
( I've mentioned "docker-host" here, but equally you could just run gcd.sh on any machine of course ) |
Hi @tom-haines, this happens to be a distinct issue from the one above. I've opened an issue (googleapis/google-cloud-java#1014) to track fixing it. The issue here is that the IP address for the Docker container isn't recognized as a local or loopback socket, so
If you need a quick workaround to upgrade |
@ajkannan , I find another incompatible error when upgrading from v0.1.6 to v0.2.2 could you pls fix? or is there any way we can convert these type of String into a parseable key in latest version of gcloud-java?
anything incompatible from the implementation of https://github.com/GoogleCloudPlatform/gcloud-java/blob/master/gcloud-java-datastore/src/main/java/com/google/cloud/datastore/Key.java? |
@ajkannan , here is an example to re-produce this issue https://github.com/email2liyang/pi-google-datastore |
Hi @email2liyang, thanks for providing repro code. The issue here is that the keys were encoded using the v1beta2 key definition, and the current Datastore version (v1beta3, which is used in To fix your problem, I recommend the following steps:
You'll either need to take those steps in some sort of bulk operation (such as a map reduce) to convert all the records you have, or you can lazily convert keys to the new specification when you need to use them. |
Hi, @ajkannan , thanks for the quick reply, I'm a little bit concern about adding dependency of v1beta2 , as it will introduce some duplicated lib into the project which may cause other unknown issue can google datastore team can fix the issue inside the new version of code which will respect old version but do not introduce so many duplicated dependencies?
|
@email2liyang, the duplicated dependencies you mentioned can be explicitly excluded via the pom. Adding this logic in |
I have posted repeatable tests to demonstrate the regressions here:
github.com/tom-haines/gcd-dot-one-seven-regression
There are various errors when trying to communicate with the latest release of the gcd emulator (v1beta3) that prevents 0.1.7 from being used with v1beta3. The same basic "connect and push tests" all work under 0.1.6.
I've included examples of the regression under both docker and localhost; using DNS lookups and IPv4 addressing. There are also scheme and scheme-less variants of the URL used.
The text was updated successfully, but these errors were encountered: