Maven的。错误代码400

时间:2014-10-13 17:23:43

标签: java eclipse google-app-engine maven

如果我在项目中运行Maven,我会收到错误代码400。运行appengine时出现问题:更新maven。我是新手这件事,我不知道如何解决它。控制台代码是:

[INFO] Scanning for projects...
[INFO] 
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building helloworld 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] >>> appengine-maven-plugin:1.9.4:update (default-cli) @ helloworld >>>
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ helloworld ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\src\main\resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ helloworld ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- appengine-maven-plugin:1.9.4:endpoints_get_discovery_doc (default) @ helloworld ---
[INFO] 
[INFO] Google App Engine Java SDK - get endpoints discovery doc...
[INFO] Using Class Name:com.google.training.helloworld.HelloWorldEndpoints
[INFO] Executing endpoints Command=[get-discovery-doc, -cp, C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\helloworld-1.0-SNAPSHOT\WEB-INF\classes;C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/classes;C:\Users\Laurynas\.m2\repository\com\google\appengine\appengine-api-1.0-sdk\1.9.4\appengine-api-1.0-sdk-1.9.4.jar;C:\Users\Laurynas\.m2\repository\com\google\appengine\appengine-endpoints\1.9.4\appengine-endpoints-1.9.4.jar;C:\Users\Laurynas\.m2\repository\javax\inject\javax.inject\1\javax.inject-1.jar, -o, C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints/WEB-INF, -w, C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints, -f, rest, com.google.training.helloworld.HelloWorldEndpoints]
Oct 13, 2014 7:55:47 PM com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
INFO: Successfully processed C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints\WEB-INF/appengine-web.xml
API Discovery Document written to C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\generated-sources\appengine-endpoints\WEB-INF/helloworldendpoints-v1-rest.discovery
[INFO] Using Class Name:com.google.training.helloworld.HelloWorldEndpoints
[INFO] Executing endpoints Command=[get-discovery-doc, -cp, C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\helloworld-1.0-SNAPSHOT\WEB-INF\classes;C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/classes;C:\Users\Laurynas\.m2\repository\com\google\appengine\appengine-api-1.0-sdk\1.9.4\appengine-api-1.0-sdk-1.9.4.jar;C:\Users\Laurynas\.m2\repository\com\google\appengine\appengine-endpoints\1.9.4\appengine-endpoints-1.9.4.jar;C:\Users\Laurynas\.m2\repository\javax\inject\javax.inject\1\javax.inject-1.jar, -o, C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints/WEB-INF, -w, C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints, -f, rpc, com.google.training.helloworld.HelloWorldEndpoints]
Oct 13, 2014 7:55:48 PM com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
INFO: Successfully processed C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints\WEB-INF/appengine-web.xml
API Discovery Document written to C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\generated-sources\appengine-endpoints\WEB-INF/helloworldendpoints-v1-rpc.discovery
[INFO] Endpoints discovery doc generation done.
[INFO] 
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ helloworld ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\src\test\resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ helloworld ---
[INFO] No sources to compile
[INFO] 
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ helloworld ---
[INFO] 
[INFO] --- maven-war-plugin:2.4:war (default-war) @ helloworld ---
[INFO] Packaging webapp
[INFO] Assembling webapp [helloworld] in [C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\helloworld-1.0-SNAPSHOT]
[INFO] Processing war project
[INFO] Copying webapp webResources [C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target/generated-sources/appengine-endpoints] to [C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\helloworld-1.0-SNAPSHOT]
[INFO] Copying webapp resources [C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\src\main\webapp]
[INFO] Webapp assembled in [120 msecs]
[INFO] Building war: C:\Users\Laurynas\Documents\ud859-master\Lesson_2\000_Hello_Endpoints\target\helloworld-1.0-SNAPSHOT.war
[INFO] 
[INFO] <<< appengine-maven-plugin:1.9.4:update (default-cli) @ helloworld <<<
[INFO] 
[INFO] --- appengine-maven-plugin:1.9.4:update (default-cli) @ helloworld ---
[INFO] 
[INFO] Google App Engine Java SDK - Updating Application
[INFO] 
[INFO] Retrieving Google App Engine Java SDK from Maven
[INFO] Updating Google App Engine Application
Oct 13, 2014 7:55:51 PM 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.
Reading application configuration data...
Oct 13, 2014 7:55:53 PM com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
INFO: Successfully processed C:/Users/Laurynas/Documents/ud859-master/Lesson_2/000_Hello_Endpoints/target/helloworld-1.0-SNAPSHOT\WEB-INF/appengine-web.xml
Oct 13, 2014 7:55:53 PM com.google.apphosting.utils.config.AbstractConfigXmlReader readConfigXml
INFO: Successfully processed C:/Users/Laurynas/Documents/ud859-master/Lesson_2/000_Hello_Endpoints/target/helloworld-1.0-SNAPSHOT\WEB-INF/web.xml


Beginning interaction for module default...

com.google.appengine.tools.admin.HttpIoException: Error posting to URL: https://appengine.google.com/api/appversion/getresourcelimits?app_id=4%2F1e6iuYCq-9PmtUjnsue-BvLgxVA5.AqgIEkLJxc8aPvB8fYmgkJxNIrjjkQI&version=1&
400 Bad Request

Client Error (400)
The request is invalid for an unspecified reason.

Unable to update app: Error posting to URL: https://appengine.google.com/api/appversion/getresourcelimits?app_id=4%2F1e6iuYCq-9PmtUjnsue-BvLgxVA5.AqgIEkLJxc8aPvB8fYmgkJxNIrjjkQI&version=1&
400 Bad Request

Client Error (400)
The request is invalid for an unspecified reason.

Please see the logs [C:\Users\Laurynas\AppData\Local\Temp\appcfg2453046990150190280.log] for further information.

任何帮助将不胜感激。

更新

Unable to update:
com.google.appengine.tools.admin.HttpIoException: Error posting to URL: https://appengine.google.com/api/appversion/getresourcelimits?app_id=4%2F1e6iuYCq-9PmtUjnsue-BvLgxVA5.AqgIEkLJxc8aPvB8fYmgkJxNIrjjkQI&version=1&
400 Bad Request

Client Error (400)
The request is invalid for an unspecified reason.

    at com.google.appengine.tools.admin.AbstractServerConnection.send1(AbstractServerConnection.java:293)
    at com.google.appengine.tools.admin.AbstractServerConnection.send(AbstractServerConnection.java:253)
    at com.google.appengine.tools.admin.AbstractServerConnection.post(AbstractServerConnection.java:232)
    at com.google.appengine.tools.admin.LoggingClientDeploySender.send(LoggingClientDeploySender.java:47)
    at com.google.appengine.tools.admin.ResourceLimits.remoteRequest(ResourceLimits.java:173)
    at com.google.appengine.tools.admin.ResourceLimits.request(ResourceLimits.java:139)
    at com.google.appengine.tools.admin.AppAdminImpl.doUpdate(AppAdminImpl.java:467)
    at com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:55)
    at com.google.appengine.tools.admin.AppCfg$UpdateAction.execute(AppCfg.java:1347)
    at com.google.appengine.tools.admin.AppCfg.executeAction(AppCfg.java:332)
    at com.google.appengine.tools.admin.AppCfg.<init>(AppCfg.java:213)
    at com.google.appengine.tools.admin.AppCfg.<init>(AppCfg.java:124)
    at com.google.appengine.tools.admin.AppCfg.main(AppCfg.java:120)
    at com.google.appengine.appcfg.AbstractAppCfgMojo.executeAppCfgCommand(AbstractAppCfgMojo.java:248)
    at com.google.appengine.appcfg.Update.execute(Update.java:32)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:133)
    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:108)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:76)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:116)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:361)
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:213)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:157)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    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)
com.google.appengine.tools.admin.AdminException: Unable to update app: Error posting to URL: https://appengine.google.com/api/appversion/getresourcelimits?app_id=4%2F1e6iuYCq-9PmtUjnsue-BvLgxVA5.AqgIEkLJxc8aPvB8fYmgkJxNIrjjkQI&version=1&
400 Bad Request

Client Error (400)
The request is invalid for an unspecified reason.

    at com.google.appengine.tools.admin.AppAdminImpl.doUpdate(AppAdminImpl.java:479)
    at com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:55)
    at com.google.appengine.tools.admin.AppCfg$UpdateAction.execute(AppCfg.java:1347)
    at com.google.appengine.tools.admin.AppCfg.executeAction(AppCfg.java:332)
    at com.google.appengine.tools.admin.AppCfg.<init>(AppCfg.java:213)
    at com.google.appengine.tools.admin.AppCfg.<init>(AppCfg.java:124)
    at com.google.appengine.tools.admin.AppCfg.main(AppCfg.java:120)
    at com.google.appengine.appcfg.AbstractAppCfgMojo.executeAppCfgCommand(AbstractAppCfgMojo.java:248)
    at com.google.appengine.appcfg.Update.execute(Update.java:32)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:133)
    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:108)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:76)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:116)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:361)
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:213)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:157)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    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)
Caused by: com.google.appengine.tools.admin.HttpIoException: Error posting to URL: https://appengine.google.com/api/appversion/getresourcelimits?app_id=4%2F1e6iuYCq-9PmtUjnsue-BvLgxVA5.AqgIEkLJxc8aPvB8fYmgkJxNIrjjkQI&version=1&
400 Bad Request

Client Error (400)
The request is invalid for an unspecified reason.

    at com.google.appengine.tools.admin.AbstractServerConnection.send1(AbstractServerConnection.java:293)
    at com.google.appengine.tools.admin.AbstractServerConnection.send(AbstractServerConnection.java:253)
    at com.google.appengine.tools.admin.AbstractServerConnection.post(AbstractServerConnection.java:232)
    at com.google.appengine.tools.admin.LoggingClientDeploySender.send(LoggingClientDeploySender.java:47)
    at com.google.appengine.tools.admin.ResourceLimits.remoteRequest(ResourceLimits.java:173)
    at com.google.appengine.tools.admin.ResourceLimits.request(ResourceLimits.java:139)
    at com.google.appengine.tools.admin.AppAdminImpl.doUpdate(AppAdminImpl.java:467)
    ... 29 more

1 个答案:

答案 0 :(得分:0)

可能或不是,但似乎您需要输入您的凭据才能上传您的应用程序:

  

上传使用appengine-skeleton-archetype:

创建的应用      

将目录更改为项目的顶级(例如,myapp)   并按如下方式调用Maven:

     

mvn appengine:update系统将提示您输入授权码   终端窗口和您的Web浏览器将在征得同意的情况下启动   您必须接受才能获得授权的屏幕。跟着   提示将任何代码从浏览器复制到命令行。