Поскольку SDK ядра приложения устарел, я пытаюсь перейти на облачный SDK Google в веб-приложении Java 8.
Я получаю следующую ошибку:
2019-10-04 11:08:54.226:WARN:oejw.WebAppContext:main: Failed startup of context c.g.a.t.d.j.DevAppEngineWebAppContext@618f627b{/,file:///foo/target/bar/,UNAVAILABLE}{/foo/target/bar}
MultiException[java.lang.IllegalArgumentException: Unable to construct RemoteRpc due to unsupported url: <http://::1:8754/v1/projects/baz>, java.lang.ExceptionInInitializerError]
at org.eclipse.jetty.util.MultiException.ifExceptionThrow(MultiException.java:124)
at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:760)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:369)
at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1497)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1459)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:852)
at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:278)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:545)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:167)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:110)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:167)
at org.eclipse.jetty.server.Server.start(Server.java:418)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:110)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113)
at org.eclipse.jetty.server.Server.doStart(Server.java:382)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
at com.google.appengine.tools.development.jetty9.JettyContainerService.startContainer(JettyContainerService.java:343)
at com.google.appengine.tools.development.AbstractContainerService.startup(AbstractContainerService.java:283)
at com.google.appengine.tools.development.AutomaticInstanceHolder.startUp(AutomaticInstanceHolder.java:26)
at com.google.appengine.tools.development.AbstractModule.startup(AbstractModule.java:87)
at com.google.appengine.tools.development.Modules.startup(Modules.java:105)
at com.google.appengine.tools.development.DevAppServerImpl.doStart(DevAppServerImpl.java:282)
at com.google.appengine.tools.development.DevAppServerImpl.access$000(DevAppServerImpl.java:47)
at com.google.appengine.tools.development.DevAppServerImpl$1.run(DevAppServerImpl.java:223)
at com.google.appengine.tools.development.DevAppServerImpl$1.run(DevAppServerImpl.java:221)
at java.security.AccessController.doPrivileged(Native Method)
at com.google.appengine.tools.development.DevAppServerImpl.start(DevAppServerImpl.java:221)
at com.google.appengine.tools.development.DevAppServerMain$StartAction.apply(DevAppServerMain.java:404)
at com.google.appengine.tools.util.Parser$ParseResult.applyArgs(Parser.java:45)
at com.google.appengine.tools.development.DevAppServerMain.run(DevAppServerMain.java:257)
at com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:248)
Мой appengine-web.xml:
<?xml version="1.0" encoding="utf-8"?>
<appengine-web-app
xmlns="http://appengine.google.com/ns/1.0">
<application>${appName}</application>
<service>${appengine-service}</service>
<version>${appengine.version}--${buildNumber}</version>
<instance-class>${instance-class}</instance-class>
<system-properties>
<property name="java.util.logging.config.file"
value="WEB-INF/logging.properties" />
</system-properties>
<ssl-enabled>true</ssl-enabled>
<inbound-services>
<service>mail</service>
</inbound-services>
<runtime>java8</runtime>
<threadsafe>true</threadsafe>
</appengine-web-app>
Моя старая конфигурация плагина:
<plugin>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-maven-plugin</artifactId>
<version>1.9.71</version>
<configuration>
<enableJarClasses>false</enableJarClasses>
<disableUpdateCheck>true</disableUpdateCheck>
</configuration>
</plugin>
Моя новая:
<plugin>
<groupId>com.google.cloud.tools</groupId>
<artifactId>appengine-maven-plugin</artifactId>
<version>2.0.0</version>
<configuration>
<projectId>bar</projectId>
<version>1.0</version>
<deploy.promote>false</deploy.promote>
<enableJarClasses>false</enableJarClasses>
<serviceAccountKeyFile>WEB-INF/ServiceAccountKey.json</serviceAccountKeyFile>
</configuration>
</plugin>
Я не знаю, где этоискаженный URL (http://::1:8754/...
).
Что я пропустил?