简体   繁体   English

如何使用Java项目的管理API在Google App Engine中进行部署

[英]How to deploy in Google app engine using admin api for Java Project

Does any one used google app engine admin api to deploy the new version for java project? 是否有人使用Google App Engine管理API部署Java项目的新版本? It is working fine as shown in the example for python project. 如python项目示例所示,它工作正常。 But for java project there is no proper guidance or examples. 但是对于Java项目,没有适当的指导或示例。

Please share the request body json if any one has one. 如果有一个,请共享请求正文json。 consider you have placed the war file in gcs. 考虑您已将war文件放置在gcs中。

https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1/apps.services.versions/create https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1/apps.services.versions/create

See Deploying a Java App . 请参阅部署Java App

You may need to convert all of your XML configuration files to YAML files. 您可能需要将所有XML配置文件转换为YAML文件。 The "appcfg" utility installs with the App Engine SDK and is probably already on your machine (search for "appcfg.cmd"). “ appcfg”实用程序随App Engine SDK一起安装,并且可能已在您的计算机上(搜索“ appcfg.cmd”)。 This utility will prepare your app properly for upload, including automatically converting your XMLs to YAMLs. 该实用程序将为您的应用正确准备上载,包括自动将XML转换为YAML。

If you don't really need to use the API you can always use "appcfg" followed by a gcloud app deploy command. 如果您确实不需要使用API​​,则可以始终使用“ appcfg”,后跟gcloud app deploy命令。 The gcloud utility is fairly straightforward and tends to get updates quickly. gcloud实用程序非常简单,可以快速获取更新。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM