| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Sorry, something went wrong.
|
Forcing users to use "GoogleCredentials" the in the new google-auth-library-java, by deprecating the GoogleCredential class in this package means that it can not longer be used to create HttpRequestFactory by calling methods like urlFetchTransport.createRequestFactory(googleCredential). Because the new GoogleCredentials Class only impliments Serializable. Not HttpExecuteInterceptor, HttpRequestInitializer and HttpUnsuccessfulResponseHandler interfaces, which methods like urlFetchTransport.createRequestFactory in the google api client expect. It seems pre-mature to deprecate the GoogleCredential class when the rest of this very client api library expects what interfaces GoogleGredential implements in order to function correctly and the replacement class doesn't even come close to implementing the interfaces that the current GoogleCredential class implements and is required by the vary apis in this package. |
Sorry, something went wrong.
|
@mitcoding google-auth-library-java provides com.google.auth.http.HttpCredentialsAdapter which wraps the credentials and should be used as an implementation for com.google.api.client.http.HttpRequestInitializer and com.google.api.client.http.HttpUnsuccessfulResponseHandler |
Sorry, something went wrong.
|
@chingor13 Using that class worked in resolving the compile time issue. however it still isn't a one to one replacement for App Engine. I'm now getting "Caused by: java.io.IOException: The Application Default Credentials are not available. They are available if running in Google Compute Engine. Otherwise, the environment variable GOOGLE_APPLICATION_CREDENTIALS must be defined pointing to a file defining the credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information." Even when I call: AppEngineCredentials.getApplicationDefault(); This was not an issue when using the older now deprecated API "GoogleCredential.getApplicationDefault()". |
Sorry, something went wrong.
|
@mitcoding Please file this as an issue and we can figure out what's going on. google-auth-library should be able to handle all everything the deprecated class was providing. |
Sorry, something went wrong.
|
@chingor13 Should the I file the issue on google-api-java or the google-auth-library? |
Sorry, something went wrong.
|
@mitcoding File it on google-auth-library as it seem like the credentials are failing to load for you before it's even making the request from the api client. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
This pull request was generated using releasetool.
05-20-2019 10:18 PDT
Implementation Changes
New Features
Dependencies
Documentation
Internal / Testing Changes