stratos-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sajith Kariyawasam <>
Subject [Discuss] Executing rolling update on a service cluster
Date Tue, 15 Dec 2015 12:11:34 GMT
Hi Devs,

At the moment in a Stratos deployment there is no easy way to do a rolling
update on a service cluster. One has to manually terminate all the running
instances of the cluster, after updating images / puppet master with
relevant fixes, and then autoscaler will spawn new instances with the
latest image. But if the cluster consists of a very large number of
instances, manual process would be a tedious task, hence we had some
discussions on automating this. I and Isuru had a discussion on this and
came up with an initial design. Please find the details below.

Rolling update feature will be available through CLI,
      for eg: *update-cluster <application_id> <cluster_id> [<image_id>]*

On update-cluster CLI command, following things would happen internally.
 - Disable autoscaling
 - Update cartridge definition if necessary (applies only for Kubernetes)
 - Terminate one member of the cluster
 - Wait for new member's member activated
 - Continue terminating all the members
 - After successful update, re-enable autoscaling

CLI operation invokes a new API, which will be added to the "StratosApiV41"
(@PUT /cluster/{clusterId}), and that Invokes a new service operation added
to AutoscalerServiceImpl,
which contains the logic (moving active members to termination pending list)

Having a new API instead of writing the logic in a client tool will make
things much cleaner and consistent and also we can easily use that API to
provide rolling update feature via Stratos UI in future.

Appreciate your thoughts on this.


Sajith Kariyawasam
*Committer and PMC member, Apache Stratos, *
*WSO2 Inc.; <>*
*Mobile: 0772269575*

View raw message