我正在使用Java appengine 1.9.56。我在web.xml中包含以下端点框架1.0条目
<servlet>
<servlet-name>SystemServiceServlet</servlet-name>
<servlet-class>com.google.api.server.spi.SystemServiceServlet</servlet-class>
<load-on-startup>0</load-on-startup>
<init-param>
<param-name>services</param-name>
<param-value>com.veersoft.services.api.VoucherAPI
</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>SystemServiceServlet</servlet-name>
<url-pattern>/_ah/spi/*</url-pattern>
</servlet-mapping>
启动服务器时出现以下异常
Uncaught exception from servlet
java.lang.NoClassDefFoundError: com/google/appengine/repackaged/com/google/common/collect/ArrayListMultimap
at com.google.api.server.spi.SystemService.<init>(SystemService.java:128)
at com.google.api.server.spi.SystemServiceServlet.createSystemService(SystemServiceServlet.java:170)
at com.google.api.server.spi.SystemServiceServlet.createSystemService(SystemServiceServlet.java:136)
at com.google.api.server.spi.SystemServiceServlet.init(SystemServiceServlet.java:59)
at org.eclipse.jetty.servlet.ServletHolder.initServlet(ServletHolder.java:643)
at org.eclipse.jetty.servlet.ServletHolder.initialize(ServletHolder.java:422)
at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:892)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:349)
at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1406)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1368)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:778)
at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:262)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:522)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
at com.google.apphosting.runtime.jetty9.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java:244)
at com.google.apphosting.runtime.jetty9.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java:182)
at com.google.apphosting.runtime.jetty9.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:97)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.dispatchServletRequest(JavaRuntime.java:650)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.dispatchRequest(JavaRuntime.java:612)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:582)
at com.google.apphosting.runtime.JavaRuntime$NullSandboxRequestRunnable.run(JavaRuntime.java:776)
at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:263)
at java.lang.Thread.run(Thread.java:745)
答案 0 :(得分:0)
Java 8运行时不支持v1框架。如果这是一个现有的应用程序,您可以选择将运行时降级到Java 7,您可以在appengine-web.xml
或upgrade to the v2 frameworks中指定。如果这是一个新的应用程序,那么您应该升级到v2框架。