title: ClassNotFoundException for RPC with GoogleAppEngine
body: <p>I tried to deploy a locally working application to the <code>GAE</code> GoogleAppEngine. It already runs fine there, except for the <code>RPC</code> calls. They all throw <code>ClassNotFoundException</code>s.</p>
  
  <p>I'm just making RPC using exactly the following code, may I have forgotten something?
  It works perfectly in devmode locally.</p>
  
  <p>client side:</p>
  
  <pre><code>@RemoteServiceRelativePath("test")
  public interface TestService extends RemoteService {
      String testRpc();
  }
  
  public interface TestServiceAsync extends RemoteService {
      void testRpc(AsyncCallback&lt;String&gt; callback);
  }  
  </code></pre>
  
  <p>Usage:</p>
  
  <pre><code>   TestServiceAsync service = GWT.create(TestService.class)
      service.testRpc(new AsyncCallback&lt;String&gt;() {
          @Override
          public void onFailure(Throwable caught) {
              Window.alert("ERROR");
          }
  
          @Override
          public void onSuccess(String result) {
              Window.alert("SUCCESS: " + result);
          }
      });
  </code></pre>
  
  <p>Server side:</p>
  
  <pre><code>package myapp.server.rpc;
  public class TestServiceImpl extends RemoteServiceServlet implements TestService {
      @Override
      public String testRpc() {
          return "OK";
      }
  }
  </code></pre>
  
  <p>web.xml:</p>
  
  <pre><code> &lt;servlet&gt;
        &lt;servlet-name&gt;TestServiceImpl&lt;/servlet-name&gt;
        &lt;servlet-class&gt;myapp.server.rpc.TestServiceImpl
        &lt;/servlet-class&gt;
     &lt;/servlet&gt;
     &lt;servlet-mapping&gt;
        &lt;servlet-name&gt;TestServiceImpl&lt;/servlet-name&gt;
        &lt;url-pattern&gt;/myapp/test&lt;/url-pattern&gt;
     &lt;/servlet-mapping&gt;
  </code></pre>
  
  <p>Result: Exception:</p>
  
  <pre><code>EXCEPTION 
  java.lang.ClassNotFoundException: my.app.server.rpc.TestServiceImpl
      at com.google.appengine.runtime.Request.process-e7c092c1e216f15a(Request.java)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
      at org.mortbay.util.Loader.loadClass(Loader.java:91)
      at org.mortbay.util.Loader.loadClass(Loader.java:71)
      at org.mortbay.jetty.servlet.Holder.doStart(Holder.java:73)
      at org.mortbay.jetty.servlet.ServletHolder.doStart(ServletHolder.java:242)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:685)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:517)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:467)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at java.lang.Thread.run(Thread.java:679)
  
  E 2013-04-23 11:03:08.915
  
  javax.servlet.ServletContext log: unavailable
  javax.servlet.UnavailableException: my.app.server.rpc.TestServiceImpl
      at org.mortbay.jetty.servlet.Holder.doStart(Holder.java:79)
      at org.mortbay.jetty.servlet.ServletHolder.doStart(ServletHolder.java:242)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:685)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:517)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:467)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:219)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:194)
      at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
      at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:438)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
      at java.lang.Thread.run(Thread.java:679)
  
  W 2013-04-23 11:03:08.924
  
  Failed startup of context com.google.apphosting.utils.jetty.RuntimeAppEngineWebAppContext@1079ff{/,/base/data/home/apps/s~myapp/1.366873782202758954}
  org.mortbay.util.MultiException[java.lang.NullPointerException, java.lang.NullPointerException, java.lang.NullPointerException]
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:656)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:517)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:467)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:219)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:194)
      at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
      at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:438)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
      at java.lang.Thread.run(Thread.java:679)
  java.lang.NullPointerException
      at java.lang.Class.isAssignableFrom(Native Method)
      at org.mortbay.jetty.servlet.ServletHolder.doStart(ServletHolder.java:256)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:685)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:517)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:467)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:219)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:194)
      at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
      at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:438)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
      at java.lang.Thread.run(Thread.java:679)
  java.lang.NullPointerException
      at java.lang.Class.isAssignableFrom(Native Method)
      at org.mortbay.jetty.servlet.ServletHolder.doStart(ServletHolder.java:256)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:685)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:517)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:467)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:219)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:194)
      at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
      at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:438)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
      at java.lang.Thread.run(Thread.java:679)
  java.lang.NullPointerException
      at java.lang.Class.isAssignableFrom(Native Method)
      at org.mortbay.jetty.servlet.ServletHolder.doStart(ServletHolder.java:256)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:685)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:517)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:467)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:219)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:194)
      at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
      at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:438)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
      at java.lang.Thread.run(Thread.java:679)
  
  C 2013-04-23 11:03:08.928
  
  Uncaught exception from servlet
  javax.servlet.UnavailableException: Initialization failed.
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:228)
      at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:194)
      at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
      at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:438)
      at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:480)
      at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:487)
      at com.google.tracing.TraceContext.runInContext(TraceContext.java:774)
      at com.google.tracing.TraceContext$DoInTraceContext.runInContext(TraceContext.java:751)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:342)
      at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:334)
      at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:484)
      at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:251)
      at java.lang.Thread.run(Thread.java:679)
  
  I 2013-04-23 11:03:08.931
  
  This request caused a new process to be started for your application, and thus caused your application code to be loaded for the first time. This request may thus take longer and use more CPU than a typical request for your application.
  </code></pre>