When creating and deleting resources in Layer0, the AWS API often quickly returns a response designating that they have received the request, but that request is not necessarily reflective of reality. AWS terms this as 'eventual consistency', and we must build retry logic in order to account for it.
ELBs and Security Groups are the biggest offenders here --- but other AWS resources have the potential to be eventually consistent as well. As such, we should build middleware in the API's client package that checks if a resource has been created or deleted before returning.
[x] LB Delete #584
[x] Env Delete #583
[x] Service Create #582
[x] API client retry when hit specific dependency errors #585
When creating and deleting resources in Layer0, the AWS API often quickly returns a response designating that they have received the request, but that request is not necessarily reflective of reality. AWS terms this as 'eventual consistency', and we must build retry logic in order to account for it.
ELBs and Security Groups are the biggest offenders here --- but other AWS resources have the potential to be eventually consistent as well. As such, we should build middleware in the API's
client
package that checks if a resource has been created or deleted before returning.