January 2019
Intermediate to advanced
690 pages
16h
English
As discussed briefly in the earlier chapter, the handler is basically a function that Lambda calls first for execution. A handler function is capable of processing incoming event data that is passed to it as well as invoking other functions or methods from your code.
A skeleton structure of a handler function is shown as follows:
exports.myHandler = function(event, context, callback) {
// Your code goes here.
callback();
}
Here, myHandler is the name of your handler function. By exporting it, we make sure that Lambda knows which function it has ...