Fix compilation error from make_shared<message_context> not supplying an argument. Create a template function to handle dispatch calls from message_dispatcher