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
Storage.readAllBytes() unauthorized when running on App Engine standard with default credentials #1007
It will work on a local environment using application default credentials, but it will throw the following error when deployed on App Engine standard (did not try on flexible):
com.google.cloud.storage.StorageException: 401
Login Required
at com.google.cloud.storage.spi.DefaultStorageRpc.translate(DefaultStorageRpc.java:98)
at com.google.cloud.storage.spi.DefaultStorageRpc.load(DefaultStorageRpc.java:362)
at com.google.cloud.storage.StorageImpl$16.call(StorageImpl.java:443)
at com.google.cloud.storage.StorageImpl$16.call(StorageImpl.java:440)
at com.google.cloud.RetryHelper.doRetry(RetryHelper.java:181)
at com.google.cloud.RetryHelper.runWithRetries(RetryHelper.java:247)
at com.google.cloud.RetryHelper.runWithRetries(RetryHelper.java:237)
at com.google.cloud.storage.StorageImpl.readAllBytes(StorageImpl.java:440)
The workaround is to use Storage.reader() to get a ReadChannel.
Activity
mziccard commentedon May 13, 2016
This is strange and I believe it does not depend on us. I need to do some digging but I might have a fix.
mziccard commentedon May 14, 2016
@clementdenis Would you mind giving a try to #1010? that should fix the
readAllBytesissue.chore: require hashes when installing dependencies in owlbot postproc…
chore(main): release 0.129.5-SNAPSHOT (#1007)
chore(deps): update dependency google-auth to v2.11.1 (#1007)
chore(deps): update dependency google-auth to v2.11.1 (#1007)
chore(deps): update dependency com.google.cloud:google-cloud-spanner-…
chore(main): release 1.115.5-SNAPSHOT (#1007)
chore(main): release 1.115.5-SNAPSHOT (#1007)