Manual scaling for KNF (helm chart) deployments
Manual scaling for KNF (helm chart) deployments
Proposers
- Emin Aktaş (Ulak Haberleşme A.Ş.)
Target MDG/TF
This feature requires changes on N2VC and LCM modules
Description
Adds the support of Kubernetes applications scaling deployed with helm charts
Helm charts simplifies the deployment of containerized applications. Within the helm chart, you can define the replica number of each application at initial level. This feature intend to add scaling feature for helm chart deployments.
Changes in N2VC: Requires new functions to call scaling action via Kubernetes CLI and determine the correct application to scale.
Changes in LCM: With 'Manual scaling for native k8s charms' feature some of the code needed for scaling action is implemented, some minor changes will be needed.
A Challenge
In the juju-bundle, you define an application name for the Kubernetes application. And this application name can be used for any action to be performed for this specific Kubernetes application. OSM will only know the application name and when the scaling action is performed, OSM will scale the defined application by using defined name in the VNFD yaml file.
When you directly scale an application with Kubernetes CLI it requires three main parameters
- Workload name - deployment, statefulset etc.
- Application name
- Replica number
Currenly, OSM only requires the application name.
This is rather challenging for Helm charts because Helm charts having different naming policies which depend on the design of the helm chart. For example, a helm chart can have one or more Kubernetes application and these application can have a static name, the chart name (which is the name of the helm chart given at instantiation time), chart name + application name or the application name. This makes even more complicated to decide which name will be taken from the user. Because when an OSM user deploy KNF deployment with helm chart, OSM will generate a helm chart name.
To resolve this, create a function to generate couple of names out of chart name and application name to find the correct application along with its workload name.
Demo or definition of done
When an OSM user can perform a manual scaling in the KNF (Helm Chart) deployment, the feature can be considered complete