# Examples This folder contains 4 different examples how AutoCanary24 can be used. You should have set the AWS credentials before you execute them. ## 1) Switch complete stacks at once not keeping the inactive stack How to run: `rake sample_1` | Steps | | | :------------- | :------------- | | Initial state: All the traffic goes to blue stack | | | Green stack is created | | | Green stack gets all the traffic | | | Blue stack will be deleted | | ## 2) Switch complete stacks at once keeping the inactive stack How to run: `rake sample_2` | Steps | | | :------------- | :------------- | | Initial state: All the traffic goes to blue stack | | | Green stack is created | | | Green stack gets all the traffic. Blue stack will not be deleted | | ## 3) Switch incrementally the stacks keeping the inactive stack How to run: `rake sample_3` | Steps | | | :------------- | :------------- | | Initial state: All the traffic goes to blue stack | | | Green stack gets some traffic | | | Green stack gets more traffic | | | Green stack gets even more traffic | | | Final state: All the traffic goes to green stack | | ## 4) Switch incrementally the stacks and rollback How to run: `rake sample_4` | Steps | | | :------------- | :------------- | | Initial state: All the traffic goes to blue stack | | | Green stack is created | | | Green stack gets some traffic | | | Green stack gets more traffic | | | Rollback: All the traffic goes again to blue stack | |