MyKE
MyKE

Reputation: 169

Lambda - Is possible to pass the object via pipeline to another lambda (PowerShell)

Is possible to send $LambdaInput into another Destination Lambda with Asynchronous invocation?

For imagination:

PS Lambda1: $LambdaInput = "ABC"; Write-Host $LambdaInput; $LambdaInput
|
|
----> PS Lambda2: Write-Host "This should be ABC from previous Lambda1 - $LambdaInput"

Lamba-to-lambda

If I hit the test from the Lambda1 it will see ABC from $LambdaInput but I can't see in logs from test button log from second Lambda2. Even in Logs Group Lambda2 has no record.

Am I missing something? Thank you.

Upvotes: 0

Views: 144

Answers (2)

MyKE
MyKE

Reputation: 169

I just realized even input from CloudWatch with constant JSON input is not being passed to second AWS Lambda in case first AWS Lambda fail.

As a workaround I hardcoded fixed input to second lambda function (which is used as a fallback and hardcoded value can be used there).

Anyway If there is possibility to pass input from CloudWatch/First lambda to second Lambda, let me know please in comments.

Thanks!

lambda-chain

Upvotes: 0

Related Questions