Create a http handler factory to fix some ObjectDisposedException