We have the following code in our application:
import awsServerlessExpress from 'aws-serverless-express';
import tracer from 'appdynamics-lambda-tracer';
tracer.init(...);
...
handler = (event, context, callback) => {
awsServerlessExpress.proxy(server, event, context);
};
tracer.mainModule(module);
It seems we cannot provide the `mainModule` function the CommonJS `module` object because this doesn't exist in an ES 6 environment (at least as the `mainModule` expects it in a CommonJS runtime environment).
Our question: How do we implement the Serverless tracer in an ES 6 module environment? Are there any code samples to help us?
Thanks!