QuestionQ20

Deployment

A developer is using AWS CloudFormation to deploy an AWS Lambda function. The developer needs to set the Lambda function's timeout value based on the environment parameter of the template. The template contains mappings of EnvironmentData for each environment's timeout value. The environment parameter and EnvironmentData mappings are as follows:

Environment parameter:

Question Image

EnvironmentData mappings:

Question Image

Which statement will meet these requirements?

  • A Timeout: !GetAtt [EnvironmentData, !Ref Environment, Timeout]
  • B Timeout: !FindInMap [EnvironmentData, !Ref Environment, Timeout]
  • C Timeout: !Select [EnvironmentData, !Ref Environment, Timeout]
  • D Timeout: !ForEach[EnvironmentData, !Ref Environment, Timeout]
Explanation

FindInMap is the CloudFormation intrinsic function for retrieving values from a Mappings section. It takes three parameters: the map name, the first-level key (Environment in this case), and the second-level key (Timeout), returning the corresponding value from the mapping structure.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!