keycloak / keycloak-benchmark

Keycloak Benchmark
https://www.keycloak.org/keycloak-benchmark/
Apache License 2.0
127 stars 70 forks source link

Fix cleaning up of the failover lambda #752

Closed mhajas closed 4 months ago

mhajas commented 4 months ago

It seems CloudWatch alarms and SNS topics are not cleaned correctly by the nightly run. There is the following error in the output logs:

An error occurred (ValidationException) when calling the DeleteFunction operation: 2 validation errors detected: Value '{"Id":"03a282bd-4954-4c9d-a950-29cef7d682d4","CallerReference":"d54738171435725144e3d2ed900ec890c7b1d04d","HealthCheckConfig":{"Port":443,"Type":"HTTPS","ResourcePath":"/lb-check","FullyQualifiedDomainName":"primary.gh-keycloak-a-gh-keycloak-b-mtq5mtkk.keycloak-benchmark.com","RequestInterval":30,"FailureThreshold":1,"MeasureLatency":false,"Inverted":false,"Disabled":false,"EnableSNI":true},"HealthCheckVersion":6}' at 'functionName' failed to satisfy constraint: Member must satisfy regular expression pattern: (arn:(aws[a-zA-Z-]*)?:lambda:)?([a-z]{2}((-gov)|(-iso(b?)))?-[a-z]+-\d{1}:)?(\d{12}:)?(function:)?([a-zA-Z0-9-_]+)(:(\$LATEST|[a-zA-Z0-9-_]+))?; Value '{"Id":"03a282bd-4954-4c9d-a950-29cef7d682d4","CallerReference":"d54738171435725144e3d2ed900ec890c7b1d04d","HealthCheckConfig":{"Port":443,"Type":"HTTPS","ResourcePath":"/lb-check","FullyQualifiedDomainName":"primary.gh-keycloak-a-gh-keycloak-b-mtq5mtkk.keycloak-benchmark.com","RequestInterval":30,"FailureThreshold":1,"MeasureLatency":false,"Inverted":false,"Disabled":false,"EnableSNI":true},"HealthCheckVersion":6}' at 'functionName' failed to satisfy constraint: Member must have length less than or equal to 140

Example run: https://github.com/keycloak/keycloak-benchmark/actions/runs/8459228754/job/23175145506

There are some dangling alarms, see: https://us-east-1.console.aws.amazon.com/cloudwatch/home?region=us-east-1#alarmsV2: