def unload(): ''' stops the http server ''' ioloop = tornado.ioloop.IOLoop.instance() ioloop.add_callback(lambda x: x.stop(), ioloop) _LOGGER.info('Unloaded HTTP element')