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

Issue 10807045: Ensure SequencedWorkerPool::Shutdown() blocks for already-started SKIP_ON_SHUTDOWN tasks (Closed)

Created:
8 years, 5 months ago by Ryan Sleevi
Modified:
8 years, 5 months ago
CC:
chromium-reviews, erikwright (departed), brettw-cc_chromium.org, akalin
Visibility:
Public.

Description

Ensure SequencedWorkerPool::Shutdown() blocks for already-started SKIP_ON_SHUTDOWN tasks SequencedWorkerPool tasks with explicit shutdown behaviours should have the following semantics: For tasks posted, but not started, before Shutdown is called: BLOCK_: MUST run SKIP_: MUST NOT run CONTINUE_: MUST NOT run For tasks started, but not completed, when Shutdown is called: BLOCK_: MUST block Shutdown SKIP_ MUST block Shutdown CONTINUE_: MUST NOT block Shutdown For tasks posted *AFTER* Shutdown is called, for all three cases, the new tasks MUST NOT be run. BUG=138120 TEST=base_unittests:SequencedWorkerPoolTest.SkipOnShutdown Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=147776

Patch Set 1 #

Patch Set 2 : Tab -> spaces #

Total comments: 1

Patch Set 3 : Review feedback #

Total comments: 10

Patch Set 4 : More review feedback #

Patch Set 5 : Review feedback #

Patch Set 6 : Test fix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+124 lines, -13 lines) Patch
M base/threading/sequenced_worker_pool.h View 1 2 2 chunks +13 lines, -7 lines 0 comments Download
M base/threading/sequenced_worker_pool.cc View 1 2 3 chunks +6 lines, -3 lines 0 comments Download
M base/threading/sequenced_worker_pool_unittest.cc View 1 2 3 4 5 4 chunks +105 lines, -3 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
Ryan Sleevi
jar: Review akalin: FYI and maybe sanity check :)
8 years, 5 months ago (2012-07-19 22:05:48 UTC) #1
jar (doing other things)
IMO, you should also edit the header file, where SKIP_ON_SHUTDOWN is described. You should illuminate ...
8 years, 5 months ago (2012-07-20 01:46:33 UTC) #2
Ryan Sleevi
Comments about comments addressed. Was that a LGTY, or were you waiting for the comment ...
8 years, 5 months ago (2012-07-20 01:58:24 UTC) #3
Ryan Sleevi
On 2012/07/20 01:58:24, Ryan Sleevi wrote: > Comments about comments addressed. Was that a LGTY, ...
8 years, 5 months ago (2012-07-20 02:03:07 UTC) #4
jar (doing other things)
http://codereview.chromium.org/10807045/diff/4003/base/threading/sequenced_worker_pool_unittest.cc File base/threading/sequenced_worker_pool_unittest.cc (right): http://codereview.chromium.org/10807045/diff/4003/base/threading/sequenced_worker_pool_unittest.cc#newcode301 base/threading/sequenced_worker_pool_unittest.cc:301: EXPECT_EQ(2*kNumTasks, result.size()); nit: (though again, not yours) spaces around ...
8 years, 5 months ago (2012-07-20 02:21:17 UTC) #5
Ryan Sleevi
http://codereview.chromium.org/10807045/diff/4003/base/threading/sequenced_worker_pool_unittest.cc File base/threading/sequenced_worker_pool_unittest.cc (right): http://codereview.chromium.org/10807045/diff/4003/base/threading/sequenced_worker_pool_unittest.cc#newcode349 base/threading/sequenced_worker_pool_unittest.cc:349: std::vector<int> result = tracker()->WaitUntilTasksComplete(3); On 2012/07/20 02:21:17, jar wrote: ...
8 years, 5 months ago (2012-07-20 02:53:59 UTC) #6
Ryan Sleevi
jar: Addressed a few of your comments from in-person. I tried to be conservative here ...
8 years, 5 months ago (2012-07-20 23:53:53 UTC) #7
jar (doing other things)
lgtm
8 years, 5 months ago (2012-07-21 00:39:51 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rsleevi@chromium.org/10807045/1005
8 years, 5 months ago (2012-07-21 00:55:03 UTC) #9
commit-bot: I haz the power
Try job failure for 10807045-1005 (retry) on mac_rel for step "compile" (clobber build). It's a ...
8 years, 5 months ago (2012-07-21 01:07:54 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rsleevi@chromium.org/10807045/8003
8 years, 5 months ago (2012-07-21 01:32:07 UTC) #11
commit-bot: I haz the power
8 years, 5 months ago (2012-07-21 04:58:06 UTC) #12
Change committed as 147776

Powered by Google App Engine
This is Rietveld 408576698