aws-samples/aws-health-aware

Name caching

grahamhar opened this issue · 0 comments

Is there an issue with the way the lookup of the name is set as a global variable in the Lambda? I might be lacking in knowledge of how lambda functions work but my understanding is once the lambda has been invoked a global variable would be set and not initialised again. As the lambda function is generally kept warm for more than the period of invocation (1 minute looking at the terraform example) then I don't see how a change in the DNS record would be picked up.

I will do a PR with a proposed fix.