如何修复停止应用引擎部署的新错误? (今天谷歌推出云工具SDK更新后) [英] how fix new error that's stopping app engine deployment? (after Google pushed a Cloud Tools SDK update today)

查看:119
本文介绍了如何修复停止应用引擎部署的新错误? (今天谷歌推出云工具SDK更新后)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 IntelliJ ,并正在部署到Google App Engine标准环境。



在Google将云工具SDK更新推送到我的开发计算机之后,出现新错误。



我无法再使用IntelliJ将当前或以前部署的工作版本部署到Google App Engine。

  **错误**:com.google.appengine.api.users包不存在导入

警告:[options] bootstrap类路径未与-source一起设置1.7
C:\ Users \Dave\AppData\Local\Temp\1500787298445-0\org\apache\jsp\clinicalTrials ** _ jsp.java **:6:* * error **:** com.google.appengine.api.users包不存在**
import com.google.appengine.api.users.User;

(注意:在4个不同的JSP文件中有17个这样的错误,IDE在导航<%@ page import =com.google.appengine.api.users.User%>行,它们都显示在用户包中,它们不是新的,并且已经工作了一段时间而没有任何问题) p>

Google发起的更新今天早些时候发生。它也破坏了我部署旧代码的能力。我的字面上有一个开发树的二进制档案(不只是一个提交),该版本将不再部署,并产生与我最新的代码相同的错误。



因此,它似乎在环境中发生了变化,而不是在代码中发生了变化。旧的代码工作二进制备份的本地部署就好了(和以前一样);它只是一个远程的发布/部署问题。



我已经看到了在开发/本地部署中导航到所有JSP文件的指导,以引发本地问题,但未检测到错误。



当前的JSP文件早期运行正常(加上我有旧的二进制备份,现在已经损坏,但之前已成功部署)。






gcloud组件安装已针对核心,gsutil,gcloud和app-engine-java执行(全部进行顺利)

gcloud init已运行(顺利运行)



gcloud组件更新 - > yield->所有组件都是最新的。



使用JDK 1.8 w / Project Language Level =7(从1个月前开始这个项目以来没有改变)。

根据其他帖子进行的更多检查:IntelliJ指向JDK(而不是JRE)。 %JAVA_HOME%是正确的。



(Google App Engine集成插件被标记为过时/某事...不确定第一次发生的时间,但我在挖掘时注意到了这一点,但似乎并不相关,因为Google云端工具似乎已经涵盖了这一点,并且已启用并且是最新的......Google插件冲突 - 您正在运行一个旧版插件(Google App Engine集成),它与已安装的Google用于Java插件的云工具 - 请点击此处停用旧插件...我尝试修复症状时单击并停用...没有帮助。)



我更新了IntelliJ IDE。没有帮助。 (从2017.1.5到2017.2版)






我在一个新的空文件夹中创建了一个干净的开发树。我遵循留言簿样本来自Google和我有同样的问题。这是一个干净的代码库(未触及的示例代码),这是继教程步骤部署。它使用本教程中的mvn命令行命令在Windows上部署得很好。当我尝试切换到 IntelliJ 执行部署时,它失败。 IntelliJ部署到本地服务器的罚款,只是无法远程部署到谷歌云appspot.com。因此,这似乎是IntelliJ IDE的特定功能。



从IntelliJ窗口...

  INFO:内建文件:\ guestbook.jsp 
警告:[选项] bootstrap类路径未与-source 1.7一起设置
C: \ Users \Dave\AppData\Local\Temp\1500868898750-0\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ appengine.api.users不存在**
import com.google.appengine.api.users.User;
$

C:\ Users中的构建活动/ staging / jsp-编译\\ Dave \AppData\Local\Temp似乎是新的......即伴随着什么时候开始麻烦......我没有看到这个临时文件夹活动在Google GAE更新之前引发了麻烦(即,没有类似的文件和文件夹在2017年7月22日前)。






Maven(命令行,Windows)编译JSP文件......如此输出所示:


模块默认的开始交互... 0%创建的分段
目录:
'C:\ Users \Dave\AppData\Local\Temp\appcfg3686517196875747128.tmp'5%
扫描jsp文件。 8%编译jsp文件。 2017年7月23日8:47:32
PM org.apache.jasper.JspC processFile INFO:Built File:\guestbook.jsp
warning:[options] bootstrap类路径未与$一起设置b $ b -source 1.7 11%生成的git存储库信息文件。 20%扫描本地磁盘上的文件。 25%启动更新。 28%克隆1
静态文件。 31%克隆24个应用程序文件。 40%上传2个文件。
52%已上传1个文件。 61%上传2个文件。 68%发送批量
包含2个文件总计1KB。 73%初始化预编译...
90%部署新版本。 95%关闭更新:新版本准备好
开始服务。 98%上传索引定义。模块
的更新默认成功完成。成功。清理临时文件
用于模块默认... [INFO]
----------------------------- ------------------------------------------ [INFO] BUILD SUCCESS [INFO]
---------------------------------------------- ------------------------- [INFO]总时间:53.733 s [INFO]完成时间:



2017-07-23T20:47:53-07:00 [INFO] Final Memory:35M / 580M [INFO]



解决方案

https:/ /github.com/GoogleCloudPlatform/google-cloud-intellij/issues/1596 ,并且不知道更多关于您的设置的信息,看起来好像您在gcloud中遇到了一个开放的错误(将在下一个版本的gcloud)。



作为临时解决方法,请参阅 https://github.com/GoogleCloudPlatform/google-cloud-eclipse/issues/2202



解决方法的要点是:



  • 将Cloud SDK复制到不含空格的路径


  • 将gcloud降级为159:gcloud组件更新--version 159.0.0


I am using IntelliJ and I am deploying to Google App Engine Standard Environment.

I have a new error after Google pushed a Cloud Tools SDK update to my development machine.

I can no longer deploy current or previously deployed working versions to Google App Engine using IntelliJ.

**error**: package com.google.appengine.api.users does not exist import 

warning: [options] bootstrap class path not set in conjunction with -source 1.7
C:\Users\Dave\AppData\Local\Temp\1500787298445-0\org\apache\jsp\clinicalTrials**_jsp.java**:6: **error**: **package com.google.appengine.api.users does not exist**
import com.google.appengine.api.users.User;

(Note: there are 17 such errors in 4 different JSP files, the IDE has no problem navigating the <%@ page import="com.google.appengine.api.users.User" %> lines, they all appear to be in users package, they are not new and have worked for some time without any trouble).

The Google-initiated update occurred earlier today. It has also broken my ability to deploy old code. I literally have a binary archive of my development tree (not just a commit) and that version will no longer deploy and generates the same error as my latest code.

So, it appears to be something that changed in the environment, not in the code. Local deployment of the old binary backup of code works just fine (as previously); it is only a remote publish/deploy problem.

I have seen guidance to navigate to all JSP files in development/local deployment to trigger local trouble, but no errors were detected.

The current JSP files worked fine earlier (plus I have the old binary backup that is now broken but previously deployed successfully).


gcloud components install has already been executed for core, gsutil, gcloud and app-engine-java (all went smoothly)

gcloud init has been run (went smoothly)

gcloud components update ->yields-> "All components are up to date."

Using JDK 1.8 w/ Project Language Level = "7" (hasn't changed since I started this project 1 month ago).

More checks made based on other posts: IntelliJ is pointing to the JDK (not the JRE). %JAVA_HOME% is correct.

("Google App Engine Integration" plugin was flagged as obsolete/something...not sure when this 1st happened but I noticed this while digging, however it seems irrelevant because "Google Cloud Tools" seems to cover this now and it is enabled and up to date..."Google Plugin Conflict - You are running an old plugin (Google App Engine Integration) that conflicts with the installed Google Cloud Tools for Java plugin. - Please click here to deactivate the old plugin."...I clicked and deactivated while trying to fix symptom...didn't help.)

I updated IntelliJ IDE. Didn't help. (from version 2017.1.5 to 2017.2)


I have created a clean development tree in a new empty folder. I followed the guestbook sample from Google and I have the same problem. That's a clean codebase (untouched sample code) and that's following tutorial steps to deploy. It deploys fine on Windows using mvn command-line commands from the tutorial. It fails when I try to switch to IntelliJ to perform the deployment. IntelliJ deploys fine to a local server, just fails to deploy to remotely to Google cloud appspot.com. So, it appears to be specific to the IntelliJ IDE.

From IntelliJ window...

INFO: Built File: \guestbook.jsp
warning: [options] bootstrap class path not set in conjunction with -source 1.7
C:\Users\Dave\AppData\Local\Temp\1500868898750-0\org\apache\jsp\**guestbook_jsp.java**:6: **error: package com.google.appengine.api.users does not exist**
import com.google.appengine.api.users.User;
                                 ^

The build activity/staging/jsp-compiling in C:\Users\Dave\AppData\Local\Temp seems to be new...i.e., concomitant with when the trouble began...I don't see this Temp folder activity preceeding the Google GAE update that initated the trouble (i.e., no similar files and folders before 7/22/2017).


Maven (command-line, Windows) has no problem compiling the JSP files...as illustrated by this output:

Beginning interaction for module default... 0% Created staging directory at: 'C:\Users\Dave\AppData\Local\Temp\appcfg3686517196875747128.tmp' 5% Scanning for jsp files. 8% Compiling jsp files. Jul 23, 2017 8:47:32 PM org.apache.jasper.JspC processFile INFO: Built File: \guestbook.jsp warning: [options] bootstrap class path not set in conjunction with -source 1.7 11% Generated git repository information file. 20% Scanning files on local disk. 25% Initiating update. 28% Cloning 1 static files. 31% Cloning 24 application files. 40% Uploading 2 files. 52% Uploaded 1 files. 61% Uploaded 2 files. 68% Sending batch containing 2 file(s) totaling 1KB. 73% Initializing precompilation... 90% Deploying new version. 95% Closing update: new version is ready to start serving. 98% Uploading index definitions. Update for module default completed successfully. Success. Cleaning up temporary files for module default... [INFO] ----------------------------------------------------------------------- [INFO] BUILD SUCCESS [INFO] ----------------------------------------------------------------------- [INFO] Total time: 53.733 s [INFO] Finished at:

2017-07-23T20:47:53-07:00 [INFO] Final Memory: 35M/580M [INFO]

解决方案

As noted on https://github.com/GoogleCloudPlatform/google-cloud-intellij/issues/1596, and without knowing more about your setup, it appears as though you are hitting an open bug in gcloud (to be fixed in the next release of gcloud). The bug being improper handling of spaces in the cloud SDK path.

As a temporary workaround see https://github.com/GoogleCloudPlatform/google-cloud-eclipse/issues/2202

The gist of the workaround being:

  • move/copy Cloud SDK to a path without spaces
  • or downgrade gcloud to 159: gcloud components update --version 159.0.0

这篇关于如何修复停止应用引擎部署的新错误? (今天谷歌推出云工具SDK更新后)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆