[ServiceWorker] Eliminate blink.mojom.ServiceWorkerRegistrationObjectInfo.handle_id

This CL stops passing registration handle id from the browser process to
the renderer process.

Before this CL, the renderer process uses the registration handle id to
differentiate a service worker registration entity against multiple
JavaScript execution contexts for service worker clients or service
worker itself, by managing the mapping between registration handle id
and JavaScript registration object in each thread-specific instance of
However, as the registration handle id is actually an unique identifier
of the (provider_id, registration_id) pair, this CL makes the renderer
process manage the mapping between registration id and JavaScript
registration object in each provider-specific instance of
ServiceWorkerProviderContext for all JavaScript execution contexts.
Thus, we do not need to pass the registration handle id in
blink.mojom.ServiceWorkerRegistrationObjectInfo anymore.

Also, we found that we do not need to manage the mapping for service
worker execution context itself, because
ServiceWorkerGlobalScope#registration is just set once immediately after
the service worker thread started and will never change later. So this
CL only manages the mapping for service worker client contexts.

Follow-up CLs will rename ServiceWorkerRegistrationHandle class to
ServiceWorkerRegistrationObjectHost, and then manage them per
ServiceWorkerProviderHost instead of per ServiceWorkerDispatcherHost.

TEST=content_unittests --gtest_filter=ServiceWorkerProviderContextTest.*

Change-Id: Ic9c68565bcb05d6bc40e9f6380bdfe66ab1577cb
Reviewed-on: https://chromium-review.googlesource.com/748907
Commit-Queue: Han Leon <leon.han@intel.com>
Reviewed-by: Kinuko Yasuda <kinuko@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Matt Falkenhagen <falken@chromium.org>
Reviewed-by: Makoto Shimazu <shimazu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#516578}
13 files changed