aws-samples / aws-refarch-wordpress

This reference architecture provides best practices and a set of YAML CloudFormation templates for deploying WordPress on AWS.
MIT No Attribution
1.08k stars 601 forks source link

Alarm creation flawed #21

Open msoosgds opened 6 years ago

msoosgds commented 6 years ago

The two alarms for EFS are being created concurrently, which can lead to a race condition and a fail:

  | 16:48:03 UTC+0100 | CREATE_COMPLETE | AWS::CloudWatch::Alarm | CriticalAlarm |  
  | 16:48:03 UTC+0100 | CREATE_FAILED | AWS::CloudWatch::Alarm | WarningAlarm | A separate request to update this alarm is in progress.
  | 16:48:03 UTC+0100 | CREATE_IN_PROGRESS | AWS::CloudWatch::Alarm | CriticalAlarm | Resource creation Initiated

As you can see, the create for one hasn't terminated when the other is started, leading to a failure of "A separate request to update this alarm is in progress.". Then it completes the alarm creation, but from then on, it's all rolled back of course because of the failure due to the concurrent creation. Please fix :)

darrylsosborne commented 6 years ago

I'm looking into this. This is the first time hearing of this condition. I'll try to reproduce the issue. If I'm unable to reproduce it (I've run this 100's of times without seeing this condition), I could possibly add an alarm dependency on one to force them to be created serially. Let me investigate.

msoosgds commented 6 years ago

Please use google to search to find similar issues:

https://www.google.co.uk/search?q=CREATE_FAILED+A+separate+request+to+update+this+alarm+is+in+progress