简体   繁体   English

杀死Cloud Foundry实例

[英]Killing a Cloud Foundry Instance

When killing a cloud foundry instance of a broker app does it restart the same one or does it take a round robin approach? 销毁代理应用程序的云铸造实例时,它会重新启动同一个应用程序吗?还是采用循环方式?

I have 3 instances on my broker app and when I send a curl delete call to an instance, it will make an attempt to bring that instance back up. 我的经纪人应用程序上有3个实例,当我向实例发送curl删除调用时,它将尝试恢复该实例。 If I continue to kill instance 0, does it kill the same instance every single time or does instance #1 become #0 and kill that one etc etc? 如果我继续杀死实例0,它是否每次都杀死同一实例,还是实例#1变成#0并杀死那个实例,依此类推?

If you have an application that it is scaled to three instances and you terminate one instance (using cf curl /v2/apps/<guid>/instances/0 -X 'DELETE' ), that instance will still exist with the same index. 如果您有一个应用程序,该应用程序可缩放到三个实例,并且终止了一个实例(使用cf curl /v2/apps/<guid>/instances/0 -X 'DELETE' ),则该实例将仍然具有相同的索引。 You can see this using the output from cf app : 您可以使用cf app的输出看到此内容:

state     since                    cpu    memory          disk          
#0   down      1970-01-01 01:00:00 AM   0.0%   0 of 0          0 of 0
#1   running   2016-08-30 07:42:23 PM   0.1%   8.1M of 128M    12.1M of 1G
#2   running   2016-08-30 07:42:24 PM   0.0%   11.4M of 128M   12.1M of 1G

So to answer your question, there is no re-ordering of instance IDs and sending multiple requests to kill one particular instance does just affect one. 因此,要回答您的问题,实例ID不会重新排序,发送多个请求杀死一个特定实例只会影响一个实例。

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

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