diff options
author | pavely@chromium.org <pavely@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-01-04 02:48:51 +0000 |
---|---|---|
committer | pavely@chromium.org <pavely@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-01-04 02:48:51 +0000 |
commit | 04a830a0906ac5d23f3fe715ad8c356e7a11652e (patch) | |
tree | 7dd99b6797477af64120d36749e51d1d3bfbba2a /sync/sync_tests.gypi | |
parent | 18db33766a265168f8850ff99dcdde3c393174db (diff) | |
download | chromium_src-04a830a0906ac5d23f3fe715ad8c356e7a11652e.zip chromium_src-04a830a0906ac5d23f3fe715ad8c356e7a11652e.tar.gz chromium_src-04a830a0906ac5d23f3fe715ad8c356e7a11652e.tar.bz2 |
Control invalidations network channel from TiclInvalidationService
This change introduces boilerplate GCMNetworkChannel implementation and switches
sync/notifier classes to refer network channel through base class
SyncNetworkChannel.
TiclInvalidationService can initialize invalidator with either PushClient or
GCM channel. On one hand goal was to not expose network channel implementation to
TiclInvalidationService, on the other hand to avoid passing channel specific
parameters across sync/notifier classes during initialization.
The solution is to introduce NetworkChannelCreator callback that takes no
parameters and returns scoped_ptr to SyncNetworkChannel. There are helper
functions in SyncNetworkChannel to create implementations for Puch/GCM clients
and helper functions in NonBlockingInvalidator to createNetworkChannelCreator.
The alternative was to create NetworkChannel factory interface and write
implementations of it for each channel type. This would provide more expressive
names, but requires interface and two implementations for simple purpose.
Review URL: https://codereview.chromium.org/116533006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242991 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sync/sync_tests.gypi')
-rw-r--r-- | sync/sync_tests.gypi | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sync/sync_tests.gypi b/sync/sync_tests.gypi index 761cb29..57e2b47 100644 --- a/sync/sync_tests.gypi +++ b/sync/sync_tests.gypi @@ -317,6 +317,7 @@ ['OS != "android"', { 'sources': [ 'notifier/fake_invalidator_unittest.cc', + 'notifier/gcm_network_channel_unittest.cc', 'notifier/invalidation_notifier_unittest.cc', 'notifier/invalidator_registrar_unittest.cc', 'notifier/non_blocking_invalidator_unittest.cc', |