Clearing browsing data doesn't wait until HttpServerProperties is cleared |
||
Issue descriptionCurrently, NetworkContext::ClearNetworkingHistorySince does not wait until changes are written to disk before returning. It should, so that when we tell the user their data has been cleared, it has, in fact, been cleared on disk as well as in memory.
,
Jan 3 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/dce5056197537fe6cb55976cc7995b5b0ce2c3dd commit dce5056197537fe6cb55976cc7995b5b0ce2c3dd Author: Matt Menke <mmenke@chromium.org> Date: Wed Jan 03 19:16:57 2018 Make NetworkContext wait until on-disk prefs have been cleared. Previously, NetworkContext::ClearNetworkingHistorySince would tell HttpServerProperties to clear data, and then immediately inform the caller that the data was cleared. The data was deleted from memory by that point, but hadn't been written to disk, and we didn't even trigger a flush to disk, at that point. This CL makes changes that. We now pass in the callback to the HttpServerProperties, which writes the data to the pref store and then tells the pref store to flush data to disk. Only once the newly cleared data has been flushed do we invoke the callback passed to NetworkContext::ClearNetworkingHistorySince. Bug: 795877 Cq-Include-Trybots: master.tryserver.chromium.android:android_cronet_tester;master.tryserver.chromium.linux:linux_mojo;master.tryserver.chromium.mac:ios-simulator-cronet;master.tryserver.chromium.mac:ios-simulator-full-configs Change-Id: I4b1ed23eb5bdbab77871c79cdd068b95c0972535 Reviewed-on: https://chromium-review.googlesource.com/834393 Reviewed-by: Andrei Kapishnikov <kapishnikov@chromium.org> Reviewed-by: Rohit Rao <rohitrao@chromium.org> Reviewed-by: Ryan Hamilton <rch@chromium.org> Commit-Queue: Matt Menke <mmenke@chromium.org> Cr-Commit-Position: refs/heads/master@{#526762} [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/components/cronet/cronet_prefs_manager.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/content/network/http_server_properties_pref_delegate.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/content/network/http_server_properties_pref_delegate.h [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/content/network/network_context.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/ios/chrome/browser/browser_state/chrome_browser_state_impl_io_data.mm [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/ios/chrome/browser/net/http_server_properties_manager_factory.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/ios/chrome/browser/net/http_server_properties_manager_factory.h [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties.h [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties_impl.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties_impl.h [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties_impl_unittest.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties_manager.cc [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties_manager.h [modify] https://crrev.com/dce5056197537fe6cb55976cc7995b5b0ce2c3dd/net/http/http_server_properties_manager_unittest.cc
,
Jan 3 2018
|
||
►
Sign in to add a comment |
||
Comment 1 by mmenke@chromium.org
, Dec 18 2017