cf-butler
cf-butler copied to clipboard
Calculate Application Instance Density per foundation
Report on average # of app instances per Diego Cell.
We could consume the total-running-application-instances metric from the /snapshot/summary endpoint.
The other info we need is the counts from the Resource Config tile section of the number of Diego Cells for each of PAS, and PAS for Windows installed tiles. (Note some foundations may have isolation segments so multiples of each tile would need to be summed).
To arrive at the answer we'd just divide the app instances into the total # of diego cells.
For the latter need to do some research on how to obtain.
Maybe look at BOSH Director HTTP API?
Parsing results from https://bosh.io/docs/director-api-v1/#list-just-deployments and https://bosh.io/docs/director-api-v1/#list-vms-detailed might yield what we're after.