3

Is it possible to setup auto-scaling capabilities for an app depending on the workload? I haven't found anything useful neither in the Developer Console nor in the docs. Is there may be a hidden possibility via the CLI?

Just wondering if this is possible as I'm doing a basic evaluation on Swisscom Application Cloud.

dobrud
  • 33
  • 1
  • 3

4 Answers4

3

There are several opensource autoscaling projects of various readiness for production use like

Pivotal Cloud Foundry supports auto-scaling of the applications out of the box (http://docs.pivotal.io/pivotalcf/1-8/appsman-services/autoscaler/autoscale-configuration.html)

Anatoly Kern
  • 601
  • 3
  • 8
2

This capability is not present at the moment, and it is not part of the (open source) cloudfoundry platform either. Some platforms provide it, but this has not been released to the community yet!

fdhex
  • 1,662
  • 2
  • 13
  • 13
1

There are various ways how you can do that. As described by Anatoly, you can obvisouly use the "Auto Scaler" Service, if this is deployed from your respective Provider.

(you can figure that out by just calling this Feature-Flags-API check: https://apidocs.cloudfoundry.org/253/feature_flags/get_the_app_scaling_feature_flag.html)

An other option is actually writing your own small auto-scaler based on the custom-defined scaling-behaviours you've to meet your application. (DIY ;))

mhochm
  • 46
  • 3
1

For PCF you can take a look at this https://github.com/Pivotal-Field-Engineering/autoscaling-cli-plugin. It should give you what you are looking for.

You will need to install it via the

cf install-plugin https://github.com/pivotal-cf-experimental/autoscaling-cli-plugin

and configure using steps similar to below

Get the details of the autoscaler from your marketplace
cf m | grep app-autoscaler
Install the auto scaler plugin using service & plan from above
cf create-service <service> <plan> myAutoScaler
Bind the service to your app (or u can do this via you deployment manifest)
cf bind-service myApp myAutoScaler
Configure your scaling parameters
cf configure-autoscaling --min-threshold ## --max-threshold ## --max-instances # --min-instances # myApp myAutoScaler
panksdmz
  • 311
  • 4
  • 7