aws cloudformation for atomic stack-update

+3 votes

I have a stack consisting of

  1. ec2 instances as an application server
  2. one ELB as a load balancer
  3. two Elasticsearch nodes

If I update the stack for whatever reason, perhaps to increase the number of application servers, all new components are ready to handle my current stack and my current stack is replaced by the new one at the same time, like atomic operations in database systems?

Since this reduction involves the desharding of existing data in Elasticsearch, does the same procedure also apply if I reduce the number of Elasticsearch nodes?

Mar 27, 2018 in AWS by Atul
• 10,220 points

retagged Oct 12, 2018 by Kalgi 52 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

When you perform a stack update, only the resources that you modify will be updated or replaced. In your use case, if you make changes in the number of nodes in your ES cluster, your EC2 and ELB instances will stay in place and will not change.

If you want to check which resources will affect the changes made by your template, you can use the  CloudFormation Change Sets to preview the changes before applying them.

If you just add the number of instances in your auto scaling group, the existing ones will remain there. However, if you reduce the number of instances in your ASG, the oldest ones will be deleted first. You can use the AutoScalingRollingUpdate policy to gain control over it.

In addition, when you upgrade, you can specify a replacement for your entire ASG with a new one, including all new instances of EC2. Using the AutoScalingReplacingUpdate policy, you can customize this behavior.

answered Mar 27, 2018 by DareDev
• 6,670 points

Related Questions In AWS

0 votes
1 answer

How to provide tags for the stack in CloudFormation Template?

In the template anatomy, you cant set ...READ MORE

answered Aug 13, 2018 in AWS by bug_seeker
• 14,980 points
2,398 views
+1 vote
1 answer
0 votes
1 answer

How to create new stack using create-change-set in AWS Cloudformation

The type of change set operation. To ...READ MORE

answered Sep 18, 2018 in AWS by Priyaj
• 56,140 points
159 views
0 votes
1 answer
0 votes
3 answers
0 votes
2 answers
+13 votes
2 answers
0 votes
1 answer

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.