a Lambda that calls the Lambda runtime from with
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import runtime as lambda_runtime | |
def send_report_end(event, context): | |
""" | |
A Lambda that calls report_done from within the code | |
""" | |
print "Beginning" | |
lambda_runtime.report_done(context.aws_request_id, None, 'Success', 0) | |
time.sleep(1) | |
print "After first done" | |
lambda_runtime.report_done(context.aws_request_id, None, 'Success', 0) | |
time.sleep(1) | |
print "After second done" | |
lambda_runtime.report_done(context.aws_request_id, None, 'Success', 0) | |
time.sleep(1) | |
print "Now really done" | |
return 'Success' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment