Add ability to build handler with middleware
Add ability to set global variables through the context