First off, I realize this question is very similar to this one: com.google.api.client.googleapis.json.GoogleJsonResponseException: 404 Not Found in google app engine connected android project
That being said, the original poster there gave little information and seemed a bit confused on web vs. Android access. I am hoping this question brings more clarity to the issue.
I am following the tutorial presented here: https://cloud.google.com/developers/articles/how-to-build-mobile-app-with-app-engine-backend-tutorial
At the point in the tutorial where it says "Test Client and Backend Communication" I am getting the following error in LogCat:
01-10 10:33:23.141: W/System.err(2059): com.google.api.client.googleapis.json.GoogleJsonResponseException: 404 Not Found
01-10 10:33:23.141: W/System.err(2059): Not Found
01-10 10:33:23.141: W/System.err(2059): at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:113)
01-10 10:33:23.141: W/System.err(2059): at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:40)
01-10 10:33:23.141: W/System.err(2059): at com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:312)
01-10 10:33:23.141: W/System.err(2059): at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1045)
01-10 10:33:23.151: W/System.err(2059): at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:410)
01-10 10:33:23.151: W/System.err(2059): at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:343)
01-10 10:33:23.151: W/System.err(2059): at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:460)
01-10 10:33:23.151: W/System.err(2059): at com.google.samplesolutions.mobileassistant.MainActivity$CheckInTask.doInBackground(MainActivity.java:77)
01-10 10:33:23.151: W/System.err(2059): at com.google.samplesolutions.mobileassistant.MainActivity$CheckInTask.doInBackground(MainActivity.java:1)
01-10 10:33:23.151: W/System.err(2059): at android.os.AsyncTask$2.call(AsyncTask.java:287)
01-10 10:33:23.151: W/System.err(2059): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
01-10 10:33:23.151: W/System.err(2059): at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:230)
01-10 10:33:23.151: W/System.err(2059): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
01-10 10:33:23.151: W/System.err(2059): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
01-10 10:33:23.151: W/System.err(2059): at java.lang.Thread.run(Thread.java:841)
The error is the same whether I execute the application on a physical device or via emulator (and change LOCAL_ANDROID_RUN
to true/false accordingly).
The local App Engine instance starts up (seemingly) ok:
Jan 10, 2014 10:09:40 AM java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
Jan 10, 2014 10:09:41 AM com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
INFO: Successfully processed D:\GDrive\development\eclipse\workspace\MobileAssistant-AppEngine\war\WEB-INF/appengine-web.xml
Jan 10, 2014 10:09:41 AM com.google.apphosting.utils.config.AbstractConfigXmlReader readConfigXml
INFO: Successfully processed D:\GDrive\development\eclipse\workspace\MobileAssistant-AppEngine\war\WEB-INF/web.xml
Jan 10, 2014 10:09:41 AM com.google.appengine.tools.development.SystemPropertiesManager setSystemProperties
INFO: Overwriting system property key 'java.util.logging.config.file', value 'C:\eclipse\plugins\com.google.appengine.eclipse.sdkbundle_1.8.8\appengine-java-sdk-1.8.8\config\sdk\logging.properties' with value 'WEB-INF/logging.properties' from 'D:\GDrive\development\eclipse\workspace\MobileAssistant-AppEngine\war\WEB-INF\appengine-web.xml'
Jan 10, 2014 10:09:41 AM com.google.apphosting.utils.jetty.JettyLogger info
INFO: Logging to JettyLogger(null) via com.google.apphosting.utils.jetty.JettyLogger
Jan 10, 2014 10:09:41 AM com.google.apphosting.utils.jetty.JettyLogger info
INFO: jetty-6.1.x
Jan 10, 2014 10:09:42 AM com.google.apphosting.utils.jetty.JettyLogger info
INFO: Started SelectChann...@127.0.0.1:8888
Jan 10, 2014 10:09:42 AM com.google.appengine.tools.development.AbstractModule startup
INFO: Module instance default is running at http://localhost:8888/
Jan 10, 2014 10:09:42 AM com.google.appengine.tools.development.AbstractModule startup
INFO: The admin console is running at http://localhost:8888/_ah/admin
Jan 10, 2014 10:09:42 AM com.google.appengine.tools.development.DevAppServerImpl doStart
INFO: Dev App Server is now running
When accessing the local admin console I can see the proper APIs are present and appear to be deployed properly:
EDIT: I have also tested the API and it is working as expected from the explorer:
There are no conflicting v1/v2 issues, there are no other apparent problems in the configuration or deployment of the app back-end. The client just "can't find it".
Has anyone seen this issue before and have any advice to offer to resolve it? Thanks!