Handle sync loads with DRP's URLLoaderThrottle

After https://chromium-review.googlesource.com/c/chromium/src/+/1565873,
another interesting sequencing scenario is a synchronous load (as in
blink::ResourceLoader::RequestSynchronously() triggered by a synchronous
XMLHttpRequest() or WorkerGlobalScope.importScripts()).  In this case,
the URLLoaderThrottle is not used on the sequence where it was created
(see https://chromium-review.googlesource.com/c/chromium/src/+/631040/).
If it calls back to the throttle manager
(manager_->MarkProxiesAsBad()), we're trying to make a mojo call on the
wrong sequence again.

The solution is similar to safe_browsing::RendererURLLoaderThrottle:
"private" mojo pipes to mojom::DataReductionProxy.  We take care to make
them private in the synchronous load case only: it's not unusual for a
single renderer to create tens of throttles, but only a small percentage
of those is for a synchronous load (and there should be fewer and fewer
of them given that synchronous XHR is deprecated).

Bug: 963353
Change-Id: Ie502b881e946d188d6613119de02b1f6c0874a30
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1609834
Commit-Queue: Wojciech Dzier┼╝anowski <wdzierzanowski@opera.com>
Reviewed-by: Tarun Bansal <tbansal@chromium.org>
Cr-Commit-Position: refs/heads/master@{#659873}
7 files changed