Automation Principles at
Helpshift
Raghu Udiyar
Production Engineering Manager @ Helpshift
Slide 2
Slide 2 text
75k+ RPS 600M+ MAU
5+ releases /
day
500 GiB / day
Slide 3
Slide 3 text
Ⅰ - Workflows
High level objective with all its logic in one place
End to End Automation, avoiding Piecemeal solutions
Slide 4
Slide 4 text
E.g. Provision
Instance Workflow
$ ansible-playbook provision.yml -e “cli_cloud=aws
cli_cluster_name=mongocl01 cli_count=6
cli_instance_type=r3.xlarge...
Single Interface encapsulates all logic of provisioning
like instance configuration, monitoring, OS configuration, etc
Slide 5
Slide 5 text
E.g. Release
Software
$ release.sh ...
Release a service while taking care dependencies, service
configuration, health-checks, etc
Ⅱ - Explicit
Control Flow
● Push vs Pull Model : We follow push model
○ E.g: AMI or agent based configuration
● Avoid Inversion of Control
● Simple, Easy to reason and maintain
● Better error handling
Slide 9
Slide 9 text
Ⅲ - Idempotent
Workflows
Idempotency at all levels, i.e. at Workflow level
Easy to reason, and well defined behaviour
Slide 10
Slide 10 text
Idempotency with
Redis cluster
▪ If cluster already exists, and configured, won't do any
side-effects if re-run
▪ Change cli_slave_count=2 results in unsurprising, and
well defined behaviour
Slide 11
Slide 11 text
Ⅳ- Think like a
Programmer
● Implement consistent Interfaces for workflows
● Abstract common tasks together (e.g. provisioning)
● Encapsulate all logic inside the respective workflows