简体   繁体   中英

Google Cloud Tools for Eclipse ClassNotFoundException for GcsFilename

I am trying to run Google's standard App Engine locally within Eclipse. I need to save a file to Cloud Storage. One of the classes I am using is GcsFilename. I am getting a "java.lang.ClassNotFoundException: com.google.appengine.tools.cloudstorage.GcsFilename" exception when I run my application.

I had to add the jar appengine-gcs-client-08.jar to my build path to get the code to compile. When it runs I get the exception mentioned above. Currently the project also includes the following libraries: BigQuery API, BigQuery Data Transfer API, and Cloud Storage. It also has these external jars: axis-1.4.jar, commons-discovery-05.jar, jasxrpc-api-1.1.jar, and wsdl5j-1.6.3.jar

What am I doing wrong?

I was wrong in my original answer here: the com.google.appengine.tools is ok and indeed there is a tutorial using the approach you describe. That tutorial describes the dependencies required when using Maven or Gradle.

You can also use Cloud Tools for Eclipse 's Libraries management feature to install the Cloud Storage client libraries into your app, but that uses a different set of classes.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM