Open miltondavila opened 8 years ago
@mdavila I have the same problem, did you find a solution?
Hi @adrianpalmquist,
I wasn't able to run this code. Neither did I get any replies from the author. There are some tutorials on Google Cloud that can be useful for uploading images to their platform.
Hi,
I have been trying to run your code, but I am getting this error:
Exception in thread "main" java.io.FileNotFoundException: "C:\Users\Milton\AndroidStudioProjects\simple-cloud-storage\src\main\resources\Experimenting-d7965105a4e3.json" (The filename, directory name, or volume label syntax is incorrect) at java.io.FileInputStream.open0(Native Method) at java.io.FileInputStream.open(FileInputStream.java:195) at java.io.FileInputStream.(FileInputStream.java:138)
at com.google.api.client.googleapis.auth.oauth2.GoogleCredential$Builder.setServiceAccountPrivateKeyFromP12File(GoogleCredential.java:560)
at com.pliablematter.cloudstorage.CloudStorage.getStorage(CloudStorage.java:228)
at com.pliablematter.cloudstorage.CloudStorage.createBucket(CloudStorage.java:125)
at com.pliablematter.cloudstorage.Demo.main(Demo.java:9)
I am structuring the cloudstorage.properties (using forward slashes for Windows):
private.key.path="C:/Users/Milton/AndroidStudioProjects/simple-cloud-storage/src/main/resources/Experimenting-d7965105a4e3.json"
I have also tried using \ instead of / but the results are the same...
I do have the file saved in that directory and it is readable.
What could the problem be?
Thanks for your help.