DataDog / datadog-cloudformation-macro

CloudFormation Macros by Datadog
Apache License 2.0
14 stars 22 forks source link

Add the ability to exclude functions from being instrumented #135

Open TophrC-dd opened 1 week ago

TophrC-dd commented 1 week ago

What does this PR do?

This pr introduces the parameter exclude that allows functions to be ignored by the transform command.

Motivation

Customers might encounter a situation where they may not want to instrument a function. This could be for many reason but one is for functions that require low latency

Testing Guidelines

I wrote a test case to ensure the that the function is not modified with layers and ensuring that the handler is not changed.

I also tested with a test deployment that had multiple functions with one function excluded. It instrumented the intended functions while leaving the desired excluded function untouched.

Additional Notes

Types of changes

Check all that apply