Migrate gcm to network service's socket APIs

With network service, net:: C++ socket access will need to be changed to using
network service's socket APIs. This CL changes gcm to using
proxy_resolving_socket.mojom instead of the C++ ProxyResolvingClientSocket.

GCM files that are changed:
- google_apis/gcm/engine/connection_factory_impl.cc
  This will request and own a network::mojom::ProxyResolvingSocketPtr
- google_apis/gcm/engine/connection_handler_impl.cc
  This will pass the mojo read/write pipes to socket streams.
- google_apis/gcm/base/socket_stream.cc
  SocketInputStream/SocketOutputStream will read from/write to mojo data pipes
  instead of the C++ socket.

Network service changes
- services/network/public/mojom/proxy_resolving_socket.mojom
  Peer address is surfaced directly when connection is established. This is
  needed to support GCM's use case. They need the peer address synchronously
  when connection is done.

Browser changes:
- NetworkContext raw mojo pointer has to be queried on the UI thread on demand.
  Therefore changes are added to pass through a callback and ui task runner.

Bug: 862608
Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;luci.chromium.try:linux_mojo;master.tryserver.chromium.mac:ios-simulator-cronet
Change-Id: Ic0c72c8ee7d9bc7deb6e8109234227f80ea3bbe3
Reviewed-on: https://chromium-review.googlesource.com/1142344
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Maks Orlovich <morlovich@chromium.org>
Reviewed-by: Sylvain Defresne <sdefresne@chromium.org>
Reviewed-by: Peter Beverloo <peter@chromium.org>
Commit-Queue: Helen Li <xunjieli@chromium.org>
Cr-Commit-Position: refs/heads/master@{#578386}
48 files changed