MCPcopy Create free account
hub / github.com/serverless/examples / BaseHandler

Class BaseHandler

aws-node-dynamic-image-resizer/src/lib/BaseHandler.js:1–16  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1export default class BaseHandler {
2 constructor() {
3 this.handlerName = this.constructor.name
4 }
5
6 async execute(event, context) {
7 console.log(`Executing handler ${this.handlerName}`)
8 return this._process(event, context)
9 }
10
11 async _process(event, context) {
12 console.log(event)
13 console.log(context)
14 console.log('Remember to overwrite this method if you need to provide custom handling logic.')
15 }
16}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected