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

Issue 2533473002: Use TaskScheduler instead of WorkerPool in client_cert_store_chromeos.cc. (Closed)

Created:
4 years ago by fdoray
Modified:
4 years ago
Reviewers:
gab, mattm
CC:
chromium-reviews, cbentzel+watch_chromium.org, stevenjb+watch_chromium.org, oshima+watch_chromium.org, davemoore+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Use TaskScheduler instead of WorkerPool in client_cert_store_chromeos.cc. This CL replaces base::WorkerPool::PostTask() with base::PostTaskWithTraits(). The following traits are used: Priority: Inherited (default) The priority is inherited from the calling context (i.e. TaskTraits are initialized with the priority of the current task). Shutdown behavior: CONTINUE_ON_SHUTDOWN Tasks posted with this mode which have not started executing before shutdown is initiated will never run. Tasks with this mode running at shutdown will be ignored (the worker will not be joined). With File IO: The task waits on synchronous file IO operations. With Wait: The task waits on things other than synchronous file IO operations (e.g. WaitableEvent, ConditionVariable, join a thread, join a process, blocking system call that doesn't involve interactions with the file system). BUG=659191 Committed: https://crrev.com/14589e9ca09b5cf03be779b0c1158cc5388def05 Cr-Commit-Position: refs/heads/master@{#436087}

Patch Set 1 #

Patch Set 2 : fix build error #

Patch Set 3 : add ScopedTaskScheduler #

Total comments: 2

Patch Set 4 : CR gab #16 (initialize ScopedTaskScheduler first) #

Patch Set 5 : CR gab #16 (CONTINUE_ON_SHUTDOWN) #

Total comments: 4

Patch Set 6 : remove explicit priority, add withwait() #

Patch Set 7 : add withfileio() #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -16 lines) Patch
M chrome/browser/chromeos/net/client_cert_store_chromeos.cc View 1 2 3 4 5 6 2 chunks +9 lines, -13 lines 0 comments Download
M chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc View 1 2 3 4 chunks +4 lines, -3 lines 0 comments Download

Depends on Patchset:

Messages

Total messages: 40 (28 generated)
fdoray
PTAL
4 years ago (2016-11-25 20:05:44 UTC) #15
gab
lgtm w/ CONTINUE_ON_SHUTDOWN and OWNERS approval of TaskPriority https://codereview.chromium.org/2533473002/diff/40001/chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc File chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc (right): https://codereview.chromium.org/2533473002/diff/40001/chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc#newcode93 chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc:93: base::test::ScopedTaskScheduler ...
4 years ago (2016-11-28 16:39:05 UTC) #16
fdoray
https://codereview.chromium.org/2533473002/diff/40001/chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc File chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc (right): https://codereview.chromium.org/2533473002/diff/40001/chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc#newcode93 chrome/browser/chromeos/net/client_cert_store_chromeos_unittest.cc:93: base::test::ScopedTaskScheduler scoped_task_scheduler_; On 2016/11/28 16:39:05, gab wrote: > Flip ...
4 years ago (2016-11-29 16:11:31 UTC) #23
fdoray
mattm@: Please review this CL. You should verify that the traits mentioned in the CL ...
4 years ago (2016-11-29 16:24:37 UTC) #25
mattm
https://codereview.chromium.org/2533473002/diff/80001/chrome/browser/chromeos/net/client_cert_store_chromeos.cc File chrome/browser/chromeos/net/client_cert_store_chromeos.cc (right): https://codereview.chromium.org/2533473002/diff/80001/chrome/browser/chromeos/net/client_cert_store_chromeos.cc#newcode86 chrome/browser/chromeos/net/client_cert_store_chromeos.cc:86: .WithPriority(base::TaskPriority::BACKGROUND) This should probably be USER_BLOCKING, or at least ...
4 years ago (2016-11-29 21:48:46 UTC) #26
fdoray
PTAnL https://codereview.chromium.org/2533473002/diff/80001/chrome/browser/chromeos/net/client_cert_store_chromeos.cc File chrome/browser/chromeos/net/client_cert_store_chromeos.cc (right): https://codereview.chromium.org/2533473002/diff/80001/chrome/browser/chromeos/net/client_cert_store_chromeos.cc#newcode86 chrome/browser/chromeos/net/client_cert_store_chromeos.cc:86: .WithPriority(base::TaskPriority::BACKGROUND) On 2016/11/29 21:48:46, mattm wrote: > This ...
4 years ago (2016-12-02 19:20:06 UTC) #28
mattm
lgtm (remove priority:background reference from description)
4 years ago (2016-12-02 22:22:26 UTC) #29
fdoray
On 2016/12/02 22:22:26, mattm wrote: > lgtm (remove priority:background reference from description) Done
4 years ago (2016-12-02 23:22:12 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2533473002/120001
4 years ago (2016-12-02 23:22:59 UTC) #34
commit-bot: I haz the power
Committed patchset #7 (id:120001)
4 years ago (2016-12-03 00:05:07 UTC) #37
commit-bot: I haz the power
Patchset 7 (id:??) landed as https://crrev.com/14589e9ca09b5cf03be779b0c1158cc5388def05 Cr-Commit-Position: refs/heads/master@{#436087}
4 years ago (2016-12-03 00:07:52 UTC) #39
fdoray
3 years, 9 months ago (2017-02-28 01:26:06 UTC) #40
Message was sent while issue was closed.
A revert of this CL (patchset #7 id:120001) has been created in
https://codereview.chromium.org/2720143003/ by fdoray@chromium.org.

The reason for reverting is: Using TaskScheduler with NSS is not safe until
TaskScheduler supports dynamically growing its thread pool..

Powered by Google App Engine
This is Rietveld 408576698