seperated middlewares (http + websockets) and cleanup processes