Move http request management in a module