Skip to content

Support !FindInMap intrinsic function #680

@keetonian

Description

@keetonian

Description:

One of the limitations of SAM is that it does not support all of the CloudFormation intrinsic functions.

SAM should support the Find In Map intrinsic function so that customers can use this feature in SAM resources. This feature works for CFN resources because SAM passes those resources directly on to CFN.

In order for !FindInMap to work, we need support for:

  1. Reading the mappings section of the template and storing it
  2. Recursively resolving !FindInMap functions
  3. Resolving CFN pseudo parameters used in !Ref, such as AWS::Region.

Steps to reproduce the issue:

  1. Use !FindInMap in the Events property of a AWS::Serverless::Function
  2. Deploy the template

Observed result:
Template fails because it cannot resolve the intrinsic function.
Expected result:
The intrinsic function should be evaluated to the correct value.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions