413387 - onResponseHeaders is not called multiple times when multiple
redirects occur.

Refactored the redirection code into HttpRedirector to ease
applications that need to access the redirect URI and then redirect.