GAE:defaultDeadline是无法识别的元素



我正在尝试更改我的GAE项目中URLFetch的截止日期。然而,我得到一个异常,告诉我这是一个无法识别的元素。在Eclipse中,我转到属性->谷歌->应用程序引擎,并确认我使用的是最新的SDK(1.9.28)

这是我的appengine-web.xml:

<?xml version="1.0" encoding="utf-8"?>
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
  <application>app</application>
  <version>1</version>
  <threadsafe>true</threadsafe>
  <appengine.api.urlfetch.defaultDeadline>60.0</appengine.api.urlfetch.defaultDeadline>
</appengine-web-app>

例外情况:

com.google.apphosting.utils.config.AppEngineConfigException: Unrecognized element <appengine.api.urlfetch.defaultDeadline>
at com.google.apphosting.utils.config.AppEngineWebXmlProcessor.processSecondLevelNode(AppEngineWebXmlProcessor.java:183)
at com.google.apphosting.utils.config.AppEngineWebXmlProcessor.processXml(AppEngineWebXmlProcessor.java:65)
at com.google.apphosting.utils.config.AppEngineWebXmlReader.processXml(AppEngineWebXmlReader.java:132)
at com.google.apphosting.utils.config.AppEngineWebXmlReader.readAppEngineWebXml(AppEngineWebXmlReader.java:76)
at com.google.appengine.devappserver.AbstractDevAppServerMojo.isVMRuntime(AbstractDevAppServerMojo.java:319)
at com.google.appengine.devappserver.AbstractDevAppServerMojo.getDevAppServerCommand(AbstractDevAppServerMojo.java:149)
at com.google.appengine.devappserver.DevAppServerRunner.execute(DevAppServerRunner.java:48)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:862)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:286)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:197)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

我认为文档中有一个错误,应该使用

<property name="appengine.api.urlfetch.defaultDeadline" value="60"/>

在CCD_ 1节内。

对不起!我会尽快修复文档错误。

编辑:https://cloud.google.com/appengine/docs/java/config/appconfig现在是固定的,它现在正确地说

<system-properties>
    <property name="appengine.api.urlfetch.defaultDeadline" value="10"/>
</system-properties>

相关内容

  • 没有找到相关文章

最新更新