Heat-Monasca-Auto-Scaling

Introduction
In Liberty, heat has introduced the support for the monasca based auto-scaling, which is similar to the ceilometer based auto-scaling in heat. To use this feature, please follow the details given below:

Setup the cloud environment

 * Install python-monascaclient [1] in all of the heat-engines, deployed in your cloud environment and restart those heat-engines.
 * Install and configure the monasca-agent [2] to monitor the VMs performance metric

Create the auto-scale template
Use the monasca template [3] as reference and update the template with required alarm-definition expression. In the expression, its mandatory to mention the 'scale_group' measurement as :

And the same 'scale_group' should be configured as metadata scale group elements (nova instances) as:

This will help monasca to aggregate the metrics from all elements in the given scale group and find out whether alarm threshold is reached as defined in the alarm expression. In usual practice, scale_group XXX is filled by stack ID or scale group ID, which gives uniqueness.

Train Workshop
A workshop demonstrating using auto-scaling with Monasca was presented at the Denver 2019 Summit. [5]

Mitaka User session
In mitaka summit, monasca based auto-scaling is demonstrated and recorded video is available here [4]

Reference

 * 1) https://pypi.python.org/pypi/python-monascaclient
 * 2) https://github.com/openstack/monasca-agent
 * 3) https://github.com/openstack/heat-templates/blob/master/hot/monasca/autoscaling.yaml
 * 4) https://www.openstack.org/summit/tokyo-2015/videos/presentation/auto-scaling-cloud-infrastructure-and-applications
 * 5) https://www.openstack.org/summit/denver-2019/summit-schedule/events/23291/scaling-should-be-easy-and-automatic-heat-and-monasca