Revert "Revert "Migrate gcm to network service's socket APIs""

This reverts commit 838e1b1949af36aec49042cd1df6d55396d0957b.

Reason for revert: Reland after fix

Mojo doesn't allow dropping response callbacks (see
https://groups.google.com/a/chromium.org/forum/#!topic/services-dev/zSNh16-tkaA
for discussion). The fix is to modify
ProxyResolvingSocketFactory::CreateProxyResolvingSocket to always invoke
the response callback even when the underlying socket is destroyed.
This CL also adds a regression test in proxy_resolving_socket_mojo_unittest.cc.

[email protected]
[email protected]
[email protected]

Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;luci.chromium.try:linux_mojo;master.tryserver.chromium.mac:ios-simulator-cronet
Change-Id: Ie9fdb93f965bbcf534253aaabe436c4de5f0666d

Bug: 862608, 868220
Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;luci.chromium.try:linux_mojo;master.tryserver.chromium.mac:ios-simulator-cronet
Change-Id: Ie9fdb93f965bbcf534253aaabe436c4de5f0666d
Reviewed-on: https://chromium-review.googlesource.com/1169345
Reviewed-by: Helen Li <[email protected]>
Reviewed-by: Maks Orlovich <[email protected]>
Reviewed-by: Daniel Cheng <[email protected]>
Reviewed-by: Peter Beverloo <[email protected]>
Commit-Queue: Helen Li <[email protected]>
Cr-Commit-Position: refs/heads/master@{#582318}
diff --git a/net/socket/ssl_client_socket_impl.h b/net/socket/ssl_client_socket_impl.h
index 150a479..4648ab72 100644
--- a/net/socket/ssl_client_socket_impl.h
+++ b/net/socket/ssl_client_socket_impl.h
@@ -125,6 +125,7 @@
   int ReadIfReady(IOBuffer* buf,
                   int buf_len,
                   CompletionOnceCallback callback) override;
+  int CancelReadIfReady() override;
   int Write(IOBuffer* buf,
             int buf_len,
             CompletionOnceCallback callback,