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

Issue 12701011: [Net] Propagate priority changes from URLRequest to HttpTransaction (Closed)

Created:
7 years, 9 months ago by akalin
Modified:
7 years, 9 months ago
Reviewers:
sky, mmenke, James Simonsen
CC:
chromium-reviews, cbentzel+watch_chromium.org, gavinp+disk_chromium.org, shishir+watch_chromium.org, jam, joi+watch-content_chromium.org, dominich+watch_chromium.org, eroman, darin-cc_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

[Net] Propagate priority changes from URLRequest to HttpTransaction This is in preparation for propagating priority changes from ResourceScheduler all the way to HostResolver and ClientSocketPool. Add some NetLog events and parameters for priority. BUG=166689 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=189829 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=189894

Patch Set 1 #

Total comments: 27

Patch Set 2 : Address comments #

Total comments: 9

Patch Set 3 : Address comments #

Patch Set 4 : Add more tests #

Total comments: 2

Patch Set 5 : Add anon namespace #

Patch Set 6 : Rebase on priority-split-off CL and fix FTP job bug #

Patch Set 7 : Tweak FTP job tests and rebase #

Patch Set 8 : Rebase #

Total comments: 11

Patch Set 9 : Address comments #

Patch Set 10 : Fix use-after-free bug #

Total comments: 12

Patch Set 11 : Remove DelegatingTransaction, solve crashes some other way, address comments #

Patch Set 12 : Address comments #

Total comments: 1

Patch Set 13 : Fix leaks #

Unified diffs Side-by-side diffs Delta from patch set Stats (+735 lines, -207 lines) Patch
M chrome/browser/predictors/resource_prefetcher.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_dispatcher_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_scheduler.cc View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_scheduler_unittest.cc View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M net/base/net_log_event_type_list.h View 1 2 1 chunk +8 lines, -0 lines 0 comments Download
M net/http/http_cache_transaction.h View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M net/http/http_cache_transaction.cc View 1 2 3 4 5 1 chunk +6 lines, -0 lines 0 comments Download
M net/http/http_cache_unittest.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +85 lines, -0 lines 0 comments Download
M net/http/http_network_transaction.h View 1 2 3 4 5 2 chunks +3 lines, -3 lines 0 comments Download
M net/http/http_network_transaction.cc View 1 2 3 4 5 2 chunks +20 lines, -14 lines 0 comments Download
M net/http/http_stream_factory_impl_job.cc View 1 2 3 4 5 2 chunks +4 lines, -1 line 0 comments Download
M net/http/http_transaction.h View 2 chunks +4 lines, -0 lines 0 comments Download
M net/http/http_transaction_unittest.h View 1 2 3 4 5 6 7 8 9 10 6 chunks +32 lines, -1 line 0 comments Download
M net/http/http_transaction_unittest.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +13 lines, -2 lines 0 comments Download
M net/net.gyp View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M net/url_request/url_request.h View 1 1 chunk +3 lines, -5 lines 0 comments Download
M net/url_request/url_request.cc View 1 2 3 4 5 6 7 2 chunks +15 lines, -0 lines 0 comments Download
M net/url_request/url_request_ftp_job.h View 1 2 3 4 5 6 7 8 5 chunks +12 lines, -5 lines 0 comments Download
M net/url_request/url_request_ftp_job.cc View 1 2 3 4 5 5 chunks +43 lines, -36 lines 0 comments Download
M net/url_request/url_request_ftp_job_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +106 lines, -0 lines 0 comments Download
M net/url_request/url_request_http_job.h View 1 2 3 4 5 6 7 8 6 chunks +67 lines, -57 lines 0 comments Download
M net/url_request/url_request_http_job.cc View 1 2 3 4 5 6 7 8 5 chunks +83 lines, -76 lines 0 comments Download
A net/url_request/url_request_http_job_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +120 lines, -0 lines 0 comments Download
M net/url_request/url_request_job.h View 1 2 3 4 5 2 chunks +7 lines, -1 line 0 comments Download
M net/url_request/url_request_job.cc View 1 2 3 4 5 1 chunk +3 lines, -0 lines 0 comments Download
M net/url_request/url_request_test_job.h View 1 2 3 4 5 2 chunks +5 lines, -0 lines 0 comments Download
M net/url_request/url_request_test_job.cc View 1 2 3 4 5 5 chunks +7 lines, -1 line 0 comments Download
M net/url_request/url_request_unittest.cc View 1 2 3 4 5 6 7 8 9 2 chunks +82 lines, -0 lines 0 comments Download

Messages

Total messages: 46 (0 generated)
akalin
+mmenke for net/ +simonjam for content/browser/loader +sky for chrome/
7 years, 9 months ago (2013-03-11 20:10:52 UTC) #1
mmenke
https://codereview.chromium.org/12701011/diff/1/net/http/http_cache_transaction.cc File net/http/http_cache_transaction.cc (right): https://codereview.chromium.org/12701011/diff/1/net/http/http_cache_transaction.cc#newcode470 net/http/http_cache_transaction.cc:470: NetLog::IntegerCallback("priority", priority)); Same comment goes here as for the ...
7 years, 9 months ago (2013-03-12 18:40:22 UTC) #2
cbentzel
General question - at one point the priorities were going to be based on an ...
7 years, 9 months ago (2013-03-12 18:58:28 UTC) #3
mmenke
Also, we aren't currently testing that a real URLRequestJob will respect its new priority. Doing ...
7 years, 9 months ago (2013-03-12 18:59:39 UTC) #4
akalin
PTAL https://codereview.chromium.org/12701011/diff/1/net/http/http_cache_transaction.cc File net/http/http_cache_transaction.cc (right): https://codereview.chromium.org/12701011/diff/1/net/http/http_cache_transaction.cc#newcode470 net/http/http_cache_transaction.cc:470: NetLog::IntegerCallback("priority", priority)); On 2013/03/12 18:40:22, mmenke wrote: > ...
7 years, 9 months ago (2013-03-12 22:08:27 UTC) #5
akalin
On 2013/03/12 18:58:28, cbentzel wrote: > General question - at one point the priorities were ...
7 years, 9 months ago (2013-03-12 22:09:14 UTC) #6
akalin
On 2013/03/12 18:59:39, mmenke wrote: > Also, we aren't currently testing that a real URLRequestJob ...
7 years, 9 months ago (2013-03-12 22:09:34 UTC) #7
mmenke
On 2013/03/12 22:09:34, akalin wrote: > On 2013/03/12 18:59:39, mmenke wrote: > > Also, we ...
7 years, 9 months ago (2013-03-12 22:21:21 UTC) #8
mmenke
I'll take a closer look at your changes tomorrow morning. My main concern is the ...
7 years, 9 months ago (2013-03-12 22:58:26 UTC) #9
mmenke
https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc File net/http/http_cache_transaction_unittest.cc (right): https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc#newcode39 net/http/http_cache_transaction_unittest.cc:39: TEST_F(HttpCacheTransactionTest, SetPriority) { I believe the HttpCache unittests have ...
7 years, 9 months ago (2013-03-13 15:24:37 UTC) #10
mmenke
Oh, and another unit test suggestion - for a request that is redirected, make sure ...
7 years, 9 months ago (2013-03-13 15:32:45 UTC) #11
akalin
https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc File net/http/http_cache_transaction_unittest.cc (right): https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc#newcode39 net/http/http_cache_transaction_unittest.cc:39: TEST_F(HttpCacheTransactionTest, SetPriority) { On 2013/03/13 15:24:38, mmenke wrote: > ...
7 years, 9 months ago (2013-03-13 16:06:45 UTC) #12
mmenke
https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc File net/http/http_cache_transaction_unittest.cc (right): https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc#newcode39 net/http/http_cache_transaction_unittest.cc:39: TEST_F(HttpCacheTransactionTest, SetPriority) { On 2013/03/13 16:06:45, akalin wrote: > ...
7 years, 9 months ago (2013-03-13 16:16:11 UTC) #13
mmenke
On 2013/03/13 16:16:11, mmenke wrote: > https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc > File net/http/http_cache_transaction_unittest.cc (right): > > https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc#newcode39 > ...
7 years, 9 months ago (2013-03-13 16:22:23 UTC) #14
mmenke
https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc File net/http/http_cache_transaction_unittest.cc (right): https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc#newcode39 net/http/http_cache_transaction_unittest.cc:39: TEST_F(HttpCacheTransactionTest, SetPriority) { On 2013/03/13 16:16:11, mmenke wrote: > ...
7 years, 9 months ago (2013-03-13 16:27:27 UTC) #15
akalin
Still working on adding the couple of unit tests you suggested, but PTAL. https://codereview.chromium.org/12701011/diff/13001/net/http/http_cache_transaction_unittest.cc File ...
7 years, 9 months ago (2013-03-13 16:57:14 UTC) #16
akalin
I think I added the tests that you wanted. I have one question, though: https://codereview.chromium.org/12701011/diff/51001/net/http/http_cache_transaction.cc ...
7 years, 9 months ago (2013-03-13 18:53:04 UTC) #17
mmenke
https://codereview.chromium.org/12701011/diff/51001/net/http/http_cache_transaction.cc File net/http/http_cache_transaction.cc (right): https://codereview.chromium.org/12701011/diff/51001/net/http/http_cache_transaction.cc#newcode470 net/http/http_cache_transaction.cc:470: network_trans_->SetPriority(priority); On 2013/03/13 18:53:04, akalin wrote: > One question: ...
7 years, 9 months ago (2013-03-13 19:01:23 UTC) #18
akalin
On 2013/03/13 19:01:23, mmenke wrote: > https://codereview.chromium.org/12701011/diff/51001/net/http/http_cache_transaction.cc > File net/http/http_cache_transaction.cc (right): > > https://codereview.chromium.org/12701011/diff/51001/net/http/http_cache_transaction.cc#newcode470 > ...
7 years, 9 months ago (2013-03-13 19:08:56 UTC) #19
mmenke
On 2013/03/13 19:08:56, akalin wrote: > On 2013/03/13 19:01:23, mmenke wrote: > > > https://codereview.chromium.org/12701011/diff/51001/net/http/http_cache_transaction.cc ...
7 years, 9 months ago (2013-03-13 19:27:58 UTC) #20
akalin
On 2013/03/13 19:08:56, akalin wrote: > > RestartNetworkRequest() does this. There may be other times ...
7 years, 9 months ago (2013-03-14 06:12:53 UTC) #21
mmenke
On 2013/03/14 06:12:53, akalin wrote: > On 2013/03/13 19:08:56, akalin wrote: > > > RestartNetworkRequest() ...
7 years, 9 months ago (2013-03-14 14:31:36 UTC) #22
akalin
Fix URLRequestFtpJob, added tests, rebased on my other CL (splitting off the priority field). PTAL!
7 years, 9 months ago (2013-03-15 14:23:45 UTC) #23
akalin
Ping! Now that r189099 is checked in, this should be ready to review.
7 years, 9 months ago (2013-03-19 22:31:44 UTC) #24
mmenke
https://codereview.chromium.org/12701011/diff/43003/net/url_request/url_request_ftp_job.h File net/url_request/url_request_ftp_job.h (right): https://codereview.chromium.org/12701011/diff/43003/net/url_request/url_request_ftp_job.h#newcode45 net/url_request/url_request_ftp_job.h:45: virtual HostPortPair GetSocketAddress() const OVERRIDE; While you're here, seems ...
7 years, 9 months ago (2013-03-20 17:12:59 UTC) #25
akalin
PTAL https://codereview.chromium.org/12701011/diff/43003/net/url_request/url_request_ftp_job.h File net/url_request/url_request_ftp_job.h (right): https://codereview.chromium.org/12701011/diff/43003/net/url_request/url_request_ftp_job.h#newcode45 net/url_request/url_request_ftp_job.h:45: virtual HostPortPair GetSocketAddress() const OVERRIDE; On 2013/03/20 17:12:59, ...
7 years, 9 months ago (2013-03-21 01:30:32 UTC) #26
mmenke
Not sure why all of your trybot runs are red despite mostly passing, but one ...
7 years, 9 months ago (2013-03-21 04:13:00 UTC) #27
akalin
On 2013/03/21 04:13:00, mmenke wrote: > Not sure why all of your trybot runs are ...
7 years, 9 months ago (2013-03-21 05:33:06 UTC) #28
akalin
On 2013/03/21 04:13:00, mmenke wrote: > Not sure why all of your trybot runs are ...
7 years, 9 months ago (2013-03-21 07:14:20 UTC) #29
mmenke
LGTM.... But what do you think of making more integrationy tests? Rather than just test ...
7 years, 9 months ago (2013-03-21 15:39:23 UTC) #30
akalin
Committing after tests pass https://codereview.chromium.org/12701011/diff/101001/net/http/http_transaction_unittest.cc File net/http/http_transaction_unittest.cc (right): https://codereview.chromium.org/12701011/diff/101001/net/http/http_transaction_unittest.cc#newcode26 net/http/http_transaction_unittest.cc:26: // pass to classes that ...
7 years, 9 months ago (2013-03-21 23:43:48 UTC) #31
akalin
On 2013/03/21 15:39:23, mmenke wrote: > LGTM.... > > But what do you think of ...
7 years, 9 months ago (2013-03-21 23:44:38 UTC) #32
mattmenke_gmail.com
On 2013/03/21 23:44:38, akalin wrote: > On 2013/03/21 15:39:23, mmenke wrote: > > LGTM.... > ...
7 years, 9 months ago (2013-03-21 23:46:15 UTC) #33
mattmenke_gmail.com
https://codereview.chromium.org/12701011/diff/101001/net/url_request/url_request_ftp_job_unittest.cc File net/url_request/url_request_ftp_job_unittest.cc (right): https://codereview.chromium.org/12701011/diff/101001/net/url_request/url_request_ftp_job_unittest.cc#newcode95 net/url_request/url_request_ftp_job_unittest.cc:95: EXPECT_EQ(DEFAULT_PRIORITY, job->priority()); On 2013/03/21 23:43:48, akalin wrote: > On ...
7 years, 9 months ago (2013-03-21 23:48:36 UTC) #34
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/akalin@chromium.org/12701011/111001
7 years, 9 months ago (2013-03-21 23:50:38 UTC) #35
commit-bot: I haz the power
Presubmit check for 12701011-111001 failed and returned exit status 1. INFO:root:Found 29 file(s). Running presubmit ...
7 years, 9 months ago (2013-03-21 23:50:52 UTC) #36
akalin
Forgot to actually add the OWNERS reviewers below: +simonjam for content/browser/loader +sky for chrome/
7 years, 9 months ago (2013-03-22 00:14:48 UTC) #37
akalin
https://codereview.chromium.org/12701011/diff/101001/net/url_request/url_request_ftp_job_unittest.cc File net/url_request/url_request_ftp_job_unittest.cc (right): https://codereview.chromium.org/12701011/diff/101001/net/url_request/url_request_ftp_job_unittest.cc#newcode95 net/url_request/url_request_ftp_job_unittest.cc:95: EXPECT_EQ(DEFAULT_PRIORITY, job->priority()); On 2013/03/21 23:48:36, mattmenke wrote: > On ...
7 years, 9 months ago (2013-03-22 00:16:36 UTC) #38
akalin
TBRing OWNERS since it's just a rename https://codereview.chromium.org/12701011/diff/121003/net/url_request/url_request_ftp_job_unittest.cc File net/url_request/url_request_ftp_job_unittest.cc (right): https://codereview.chromium.org/12701011/diff/121003/net/url_request/url_request_ftp_job_unittest.cc#newcode98 net/url_request/url_request_ftp_job_unittest.cc:98: job->SetPriority(LOWEST); As ...
7 years, 9 months ago (2013-03-22 00:22:02 UTC) #39
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/akalin@chromium.org/12701011/121003
7 years, 9 months ago (2013-03-22 00:26:14 UTC) #40
James Simonsen
lgtm
7 years, 9 months ago (2013-03-22 00:36:26 UTC) #41
akalin
On 2013/03/21 23:46:15, mattmenke wrote: > Those which issue requests after setting the priority would ...
7 years, 9 months ago (2013-03-22 16:17:56 UTC) #42
akalin
Committed patchset #12 manually as r189829 (presubmit successful).
7 years, 9 months ago (2013-03-22 16:24:16 UTC) #43
sky
LGTM
7 years, 9 months ago (2013-03-22 19:07:07 UTC) #44
akalin
On 2013/03/22 19:07:07, sky wrote: > LGTM Relanding after fixing memory leaks
7 years, 9 months ago (2013-03-22 20:17:13 UTC) #45
akalin
7 years, 9 months ago (2013-03-22 20:17:59 UTC) #46
Message was sent while issue was closed.
Committed patchset #13 manually as r189894 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698