javagoogle-app-enginegoogle-cloud-endpointsgcloudgcloud-java

Google Cloud Java Client library not compiling through gradle


I'm using google cloud endpoints as the backend server and google cloud storage to host the images for the project. Now I want to make an endpoint to upload a image file to the google cloud storage bucket. For that I have ended up on this google cloud java client github page

They say, if you want to compile using gradle, then use this line:

compile 'com.google.gcloud:gcloud-java:jar:0.1.0'

but when I add this line to the gradle file, then it gives error while compiling:

Error:(35, 13) Failed to resolve: com.google.gcloud:gcloud-java:jar

How do I solve this problem?

Thanks!


Solution

  • Looks like this was answered over on GitHub, but just for posterity, it looks like with Gradle the line should be

    compile 'com.google.gcloud:gcloud-java:0.1.0'
    

    (Note this removed the :jar piece.)