I'm looking into the serverless-plugin-split-stacks
plugin of the serverless framework since I've hit the CloudFormation limit of 200 resources. In the Migration Strategies section of its Github page, it says that I have three options:
- Per Lambda
- Per Type
- Per Lambda Group
The first two, I kinda get what they mean (but I'm not %100 sure). My question here is about the last option. What is a lambda group? And how can I group my lambda functions? Is it something done manually or they are grouped automatically?
Taking a look into the plugin code per-group-function.js
The plugin auto-group based on the
nestedStackCount
option.So, as an example, the following
serverless.yml
:Will group into 10 stacks as:
Based on the condition on the script, you need to set
nestedStackCount
equals or greater than 3.