Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1956)

Unified Diff: android_webview/browser/net/aw_url_request_context_getter.cc

Issue 2835233003: Use TaskScheduler instead of blocking pool in aw_url_request_context_getter.cc. (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/browser/net/aw_url_request_context_getter.cc
diff --git a/android_webview/browser/net/aw_url_request_context_getter.cc b/android_webview/browser/net/aw_url_request_context_getter.cc
index a3174299e02bf6cd5e2ce1da1445cf4d05d8e946..e47bef5de9257d9bd2fae2373011bd2909d1621d 100644
--- a/android_webview/browser/net/aw_url_request_context_getter.cc
+++ b/android_webview/browser/net/aw_url_request_context_getter.cc
@@ -22,6 +22,7 @@
#include "base/files/file_path.h"
#include "base/memory/ptr_util.h"
#include "base/strings/string_number_conversions.h"
+#include "base/task_scheduler/post_task.h"
#include "base/threading/sequenced_worker_pool.h"
#include "components/prefs/pref_service.h"
#include "content/public/browser/browser_thread.h"
@@ -220,9 +221,9 @@ void AwURLRequestContextGetter::InitializeURLRequestContext() {
browser_context->GetPath().Append(kChannelIDFilename);
scoped_refptr<net::SQLiteChannelIDStore> channel_id_db;
channel_id_db = new net::SQLiteChannelIDStore(
- channel_id_path,
- BrowserThread::GetBlockingPool()->GetSequencedTaskRunner(
- BrowserThread::GetBlockingPool()->GetSequenceToken()));
+ channel_id_path, base::CreateSequencedTaskRunnerWithTraits(
+ base::TaskTraits().MayBlock().WithPriority(
+ base::TaskPriority::BACKGROUND)));
channel_id_service.reset(new net::ChannelIDService(
new net::DefaultChannelIDStore(channel_id_db.get())));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698