This is the code of two lambdas that were used for a demo on monitoring AWS Serverless applications using AWS X-Ray. The two lambdas are deployed using a CloudFormation template.
Deployment of the sample is done via CloudFormation,
sh deploy.sh [profile name]