This means that you do not call context.done () before returning from your function or that your work does not end in lambda timeout.
For the first opportunity, you have several blocks of code in your example:
if (srcBucket == dstBucket) { console.error("Destination bucket must not match source bucket."); return; }
All this should be like this:
if (srcBucket == dstBucket) { var errorText = "Destination bucket must not match source bucket." console.error(errorText); context.done(errorText); return; }
If you pass any arguments to context.done (), then they assume that the first one is an error. (If you have no errors, just call context.done (), as you already do at the end of your waterfall).
So it is likely that one of these error cases is hit, but you are not getting the error back from lambda.
Another way that can happen is that S3 calls to getObject and putObject take longer than the assigned value of the lambda function. You can try increasing it to 60 seconds in the "config" tab of the parameters of the lambda function to find out if you will begin to receive answers.
source share