-
Notifications
You must be signed in to change notification settings - Fork 209
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
Anonymous Authentication in Java #283
Comments
I second this. Spend the better part of the day trying to get this fake-gcs-server to run with the Java Library. Always end up with
when I try to access a file. I tried a bunch of different configurations like |
Hi there, I'm not very familiar with the Java sdk, but from previous issues it seems that the Java SDK uses gRPC? Also, that error indicates that the SDK is likely trying to authenticate directly with Google API, as fake-gcs-server doesn't handle any authentication and never returns a 401. |
Yeah you are right, google sadly didn't lead me to the issues you mentioned, thank you very much for the clarification. Might be that same issue. I use the docker version of the fake-gcs-server, the fix described in #146 will most likely not be feasible in our current setup. bummer! Thank you anyways for developing the fake server in the first place, doing gods work there. |
Been able to do it with something like this:
to point the service on localhost, plus:
Still having some problems with upload, but that's a different issue I suppose. |
Indirectly related to this issue: |
There is an easier way (I believe) to set up the Java client in order not to use SSL authentication: a custom instance of HttpTransportFactory needs to be created where Http transport without authentication is built. Code bellow is in Scala, but in Java it would look almost the same:
And then it can be supplied to HttpTransportOptions builder:
|
@lapep awesome, have you tried if it is compatible with the |
@paualarco Unfortunately, It looks like the Java client is not supported by Found the same error I am getting with Java client when browsing Github Issue page: #142 |
Java should be working now that #142 is closed. Authentication is not something fake-gcs-server can handle though, you need the anonymous clients. Closing this, but feel free to reopen this or a new issue in case of questions or issues! |
Hello!
There is no examples on how to use this emulator with a Java Application, do you know if it is even possible?
I have not found anything related with Google Anonymous Credentials from the Java api...
The text was updated successfully, but these errors were encountered: