如何使用appcfg。使用谷歌的eclipse插件创建的google应用程序引擎项目的py ?

时间:2023-01-24 17:49:24

I have created a google-app-engine java project in Eclipse using Google's Eclipse plugin. My previous attempt to deploy failed. Now, when I retry, I get the following message:

我使用谷歌的Eclipse插件在Eclipse中创建了一个Google -app-engine java项目。我之前的部署尝试失败了。现在,当我重试时,我得到以下信息:

Unable to update app: Error posting to URL : http://appengine.google.com/api/appversion/create?app_id=mybdaywisherversion=1 409 conflict Another transaction for this user is already in progress for this app and major version. That user can undo the transaction with appcfg.py's "rollback" command.

无法更新app:错误发布到URL: http://appengine.google.com/api/appversion/create?app_id=mybdaywisherversion=1 409冲突此用户的另一个事务已经在此应用程序和主版本中进行。该用户可以使用appcfg撤消事务。py“回滚”的命令。

Now, I have always used the google-app-engine features from inside Eclipse only and have not a clue how to run the appcfg.py command.

现在,我一直只从Eclipse内部使用google-app-engine特性,不知道如何运行appcfg。py命令。

Could not get much help from documentation available over the internet. The only thing I could make out was for mac (I'm on mac), the command to be used is appcfg.sh. Inside Eclipse, I looked where App-Engine SDK is located on my machine and went to that location. Even found appcfg.sh there. But when I try to run it, it only reports the error "command not found". Tried various alternatives to run it (like tried running it with sudo, tried running it as ./appcfg.sh by going to whether its located) but no success

无法从internet上提供的文档中得到多少帮助。我唯一知道的是mac(我在mac上),要使用的命令是appcfg.sh。在Eclipse中,我查看了应用程序引擎SDK在我的机器上的位置,并进入了那个位置。甚至发现appcfg。sh。但是当我尝试运行它时,它只报告错误“没有找到命令”。尝试了各种方法来运行它(比如尝试用sudo运行它,尝试运行它。/appcfg)。通过去是否它的位置)但是没有成功

Can someone please tell me the step I will have to follow to run the apcfg command?

谁能告诉我运行apcfg命令需要遵循的步骤吗?

8 个解决方案

#1


11  

As the result of an Internal Server Error during app deployment, I am now left with a pending transaction, that I need to rollback before I can deploy again.

由于在应用程序部署期间发生了内部服务器错误,我现在只剩下一个待处理事务,需要回滚才能再次部署。

Creating staging directory Scanning for jsp files. Scanning files on local disk. Initiating update. java.io.IOException: Error posting to URL: 409 Conflict Another transaction by user is already in progress for this app and major version. That user can undo the transaction with appcfg.py's "rollback" command.

为jsp文件创建暂存目录扫描。扫描本地磁盘上的文件。开始更新。. io .IOException:错误发布到URL: 409冲突本应用和主版本的另一个用户事务已经在进行中。该用户可以使用appcfg撤消事务。py“回滚”的命令。

this was how I did it (all from the command line) which is a slightly simpler method, which achieved the same effect.....

我就是这样做的(全部来自于命令行),这是一种稍微简单一点的方法,达到了同样的效果……

C:\Documents and Settings\Amit\My Documents\newproject>"C:\Program Files\eclipse\plugins\com.google.appengine.eclipse.sdkbundle_1.2.5.v200909021031\appengine-java-sdk-1.2.5\bin\appcfg" rollback war

C:\Documents and Settings\Amit\My文档\是否>“C:\ Program Files \ eclipse \ plugins \ com.google.appengine.eclipse.sdkbundle_1.2.5.v200909021031 \ appengine-java-sdk-1.2.5 \ bin \ appcfg“回滚的战争

Reading application configuration data...

读取应用程序配置数据……

2009-09-17 20:47:35.859::INFO: Logging to STDERR via org.mortbay.log.StdErrLog Beginning server interaction for idebanet... 0% Rolling back the update. Success. Cleaning up temporary files...

发布时间:点击:2次-点击:2次- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -StdErrLog开始服务器交互的idebanet…0%回滚更新。成功。清理临时文件…

C:\Documents and Settings\Amit\My Documents\newproject>

C:\Documents and Settings\Amit\My文档\是否>

Courtesy:JOHN

礼貌:约翰

#2


6  

I dont think these answers were that helpful.

我不认为这些答案是有帮助的。

  1. using the commmand line cd into you application directory. for me this is

    在应用程序目录中使用命令行cd。对我来说这是

    cd /Sites/appengine_myapp

    cd /网站/ appengine_myapp

  2. Now you have done this.

    现在你已经做到了。

    appcfg.py --no_cookies --email=YOUR_EMAIL_HERE@gmail.com --passin rollback ./

    appcfg。py——no_cookies——电子邮件=YOUR_EMAIL_HERE@gmail.com—passin rollback ./。

  3. You should be prompted for your password.

    应该提示您输入密码。

#3


4  

Try running appcfg.py with rollback option. See the docs:

尝试运行appcfg。py和回滚选项。看到文档:

appcfg.py [options] rollback

appcfg。py[选项]回滚

Undoes a partially completed update for the given application. You can use this if an update was interrupted, and the command is reporting that the application cannot be updated due to a lock.

取消对给定应用程序的部分完成的更新。如果更新被中断,并且命令报告由于锁而不能更新应用程序,则可以使用此命令。

#4


4  

for mac / linux user: 1.cd /"sdkdirectory"/bin 2. chmod +x appcfg.sh 3. ./appcfg.sh -s appengine.google.com -e XXX@Gmail.com rollback /Users/"...."/workspace/yourapp/war

对于mac / linux用户:1。cd / / bin 2“sdkdirectory”。chmod + x appcfg。sh / appcfg 3。。sh - e - s appengine.google.com XXX@Gmail.com滚/用户/“....”/ workspace / yourapp战争

#5


3  

Better perspective gained about the problem.

对这个问题有更好的看法。

Documenting the problem here for the benefit of on-lookers:

为旁观者的利益记录问题:

I was using Google's Plugin for Eclipse for a Google App Engine project. An attempt to deploy the application on app-engine server failed because of network problems. Subsequent attempts were failing because the previous attempt had created some kind of lock and that transaction had to be rolled back. The plugin does not provide any way to do this. One has to use appcfg program over command line to rollback. http://code.google.com/appengine/docs/java/tools/eclipse.html has details. The problem I was facing was occuring becuase of OS level permissions on appcfg.sh. Ga ve permission to self using chmod and could get it working.

我用谷歌的Eclipse插件来做一个谷歌应用程序引擎项目。在app-engine服务器上部署应用程序的尝试由于网络问题而失败。随后的尝试失败了,因为之前的尝试创建了某种锁,并且事务必须回滚。插件没有提供任何方法来实现这一点。必须在命令行上使用appcfg程序进行回滚。http://code.google.com/appengine/docs/java/tools/eclipse.html的细节。我所面临的问题出现在appcfg.sh上的OS级别权限。Ga允许自己使用chmod,并且可以让它工作。

#6


0  

When you are using Linux, try a solution posted in this link:

当您使用Linux时,请尝试在此链接中发布的解决方案:

http://www.patternizando.com.br/2011/04/another-transaction-that-user-can-undo-the-transaction-with-appcfg-pys-rollback-command-gae/

http://www.patternizando.com.br/2011/04/another-transaction-that-user-can-undo-the-transaction-with-appcfg-pys-rollback-command-gae/

#7


0  

for deploying your application using command line , follow these steps:

要使用命令行部署应用程序,请执行以下步骤:

cd "/Library/Google/google_appengine"
./appcfg.py update "path-to-project/src"

you will be prompted for your email and password.

你会被提示输入你的电子邮件和密码。

#8


0  

I was having issues to run those appcfg provided by Eclipse. I had to install Python+ App Engine sdk for python and benefit from appcfg.py functinnalities. It was on Windows though.

我在运行Eclipse提供的appcfg时遇到了一些问题。我必须为Python安装Python+应用程序引擎sdk,并从appcfg中获益。py functinnalities。不过是在Windows上。

#1


11  

As the result of an Internal Server Error during app deployment, I am now left with a pending transaction, that I need to rollback before I can deploy again.

由于在应用程序部署期间发生了内部服务器错误,我现在只剩下一个待处理事务,需要回滚才能再次部署。

Creating staging directory Scanning for jsp files. Scanning files on local disk. Initiating update. java.io.IOException: Error posting to URL: 409 Conflict Another transaction by user is already in progress for this app and major version. That user can undo the transaction with appcfg.py's "rollback" command.

为jsp文件创建暂存目录扫描。扫描本地磁盘上的文件。开始更新。. io .IOException:错误发布到URL: 409冲突本应用和主版本的另一个用户事务已经在进行中。该用户可以使用appcfg撤消事务。py“回滚”的命令。

this was how I did it (all from the command line) which is a slightly simpler method, which achieved the same effect.....

我就是这样做的(全部来自于命令行),这是一种稍微简单一点的方法,达到了同样的效果……

C:\Documents and Settings\Amit\My Documents\newproject>"C:\Program Files\eclipse\plugins\com.google.appengine.eclipse.sdkbundle_1.2.5.v200909021031\appengine-java-sdk-1.2.5\bin\appcfg" rollback war

C:\Documents and Settings\Amit\My文档\是否>“C:\ Program Files \ eclipse \ plugins \ com.google.appengine.eclipse.sdkbundle_1.2.5.v200909021031 \ appengine-java-sdk-1.2.5 \ bin \ appcfg“回滚的战争

Reading application configuration data...

读取应用程序配置数据……

2009-09-17 20:47:35.859::INFO: Logging to STDERR via org.mortbay.log.StdErrLog Beginning server interaction for idebanet... 0% Rolling back the update. Success. Cleaning up temporary files...

发布时间:点击:2次-点击:2次- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -StdErrLog开始服务器交互的idebanet…0%回滚更新。成功。清理临时文件…

C:\Documents and Settings\Amit\My Documents\newproject>

C:\Documents and Settings\Amit\My文档\是否>

Courtesy:JOHN

礼貌:约翰

#2


6  

I dont think these answers were that helpful.

我不认为这些答案是有帮助的。

  1. using the commmand line cd into you application directory. for me this is

    在应用程序目录中使用命令行cd。对我来说这是

    cd /Sites/appengine_myapp

    cd /网站/ appengine_myapp

  2. Now you have done this.

    现在你已经做到了。

    appcfg.py --no_cookies --email=YOUR_EMAIL_HERE@gmail.com --passin rollback ./

    appcfg。py——no_cookies——电子邮件=YOUR_EMAIL_HERE@gmail.com—passin rollback ./。

  3. You should be prompted for your password.

    应该提示您输入密码。

#3


4  

Try running appcfg.py with rollback option. See the docs:

尝试运行appcfg。py和回滚选项。看到文档:

appcfg.py [options] rollback

appcfg。py[选项]回滚

Undoes a partially completed update for the given application. You can use this if an update was interrupted, and the command is reporting that the application cannot be updated due to a lock.

取消对给定应用程序的部分完成的更新。如果更新被中断,并且命令报告由于锁而不能更新应用程序,则可以使用此命令。

#4


4  

for mac / linux user: 1.cd /"sdkdirectory"/bin 2. chmod +x appcfg.sh 3. ./appcfg.sh -s appengine.google.com -e XXX@Gmail.com rollback /Users/"...."/workspace/yourapp/war

对于mac / linux用户:1。cd / / bin 2“sdkdirectory”。chmod + x appcfg。sh / appcfg 3。。sh - e - s appengine.google.com XXX@Gmail.com滚/用户/“....”/ workspace / yourapp战争

#5


3  

Better perspective gained about the problem.

对这个问题有更好的看法。

Documenting the problem here for the benefit of on-lookers:

为旁观者的利益记录问题:

I was using Google's Plugin for Eclipse for a Google App Engine project. An attempt to deploy the application on app-engine server failed because of network problems. Subsequent attempts were failing because the previous attempt had created some kind of lock and that transaction had to be rolled back. The plugin does not provide any way to do this. One has to use appcfg program over command line to rollback. http://code.google.com/appengine/docs/java/tools/eclipse.html has details. The problem I was facing was occuring becuase of OS level permissions on appcfg.sh. Ga ve permission to self using chmod and could get it working.

我用谷歌的Eclipse插件来做一个谷歌应用程序引擎项目。在app-engine服务器上部署应用程序的尝试由于网络问题而失败。随后的尝试失败了,因为之前的尝试创建了某种锁,并且事务必须回滚。插件没有提供任何方法来实现这一点。必须在命令行上使用appcfg程序进行回滚。http://code.google.com/appengine/docs/java/tools/eclipse.html的细节。我所面临的问题出现在appcfg.sh上的OS级别权限。Ga允许自己使用chmod,并且可以让它工作。

#6


0  

When you are using Linux, try a solution posted in this link:

当您使用Linux时,请尝试在此链接中发布的解决方案:

http://www.patternizando.com.br/2011/04/another-transaction-that-user-can-undo-the-transaction-with-appcfg-pys-rollback-command-gae/

http://www.patternizando.com.br/2011/04/another-transaction-that-user-can-undo-the-transaction-with-appcfg-pys-rollback-command-gae/

#7


0  

for deploying your application using command line , follow these steps:

要使用命令行部署应用程序,请执行以下步骤:

cd "/Library/Google/google_appengine"
./appcfg.py update "path-to-project/src"

you will be prompted for your email and password.

你会被提示输入你的电子邮件和密码。

#8


0  

I was having issues to run those appcfg provided by Eclipse. I had to install Python+ App Engine sdk for python and benefit from appcfg.py functinnalities. It was on Windows though.

我在运行Eclipse提供的appcfg时遇到了一些问题。我必须为Python安装Python+应用程序引擎sdk,并从appcfg中获益。py functinnalities。不过是在Windows上。