DataDog / serverless-plugin-datadog

Serverless plugin to automagically instrument your Lambda functions with Datadog
Apache License 2.0
96 stars 49 forks source link

chore: Refactor and add test for sfn->Lambda context injection when P… #524

Closed lym953 closed 2 months ago

lym953 commented 2 months ago

…arameters is string

What does this PR do?

When the Parameters field of an "InvokeLambda" step is a string instead of an object, currently we skip context injection.

This PR:

  1. refactors code by flipping if condition
  2. print a warning message in this case
  3. add a test case

Motivation

Testing Guidelines

Pass the added test

Additional Notes

Types of changes

Check all that apply

lym953 commented 2 months ago

/merge

dd-devflow[bot] commented 2 months ago

:steam_locomotive: MergeQueue: pull request added to the queue

The median merge time in main is 2m.

Use /merge -c to cancel this operation!