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

Issue 9190031: DnsClient refactoring + features (timeout, suffix search, server rotation). (Closed)

Created:
8 years, 11 months ago by szym
Modified:
8 years, 11 months ago
Reviewers:
cbentzel, mmenke
CC:
chromium-reviews, cbentzel+watch_chromium.org, eroman, darin-cc_chromium.org, mmenke
Visibility:
Public.

Description

DnsClient refactoring + features (timeout, suffix search, server rotation). DnsClient::Request ==> DnsTransaction DnsTransaction ==> DnsTransactionImpl DnsClient ==> DnsTransactionFactory BUG=109949 TEST=net_unittests --gtest_filter=Dns* Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=119146

Patch Set 1 #

Patch Set 2 : Fixes. #

Patch Set 3 : Added comments. Fixed tests. #

Total comments: 47

Patch Set 4 : Responded to review. Renamed DnsClient -> DnsTransactionFactory. Completed logging. #

Total comments: 7

Patch Set 5 : Renamed dns_client -> dns_transaction. #

Total comments: 14

Patch Set 6 : Added unit tests. Depends on CL 9251019 #

Total comments: 10

Patch Set 7 : Addressed code review. #

Total comments: 8

Patch Set 8 : Rebased to trunk. #

Patch Set 9 : Addressed review. Updated Copyright year. #

Patch Set 10 : Delinted. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1311 lines, -1147 lines) Patch
M net/base/dns_util.h View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -2 lines 0 comments Download
M net/base/net_log_event_type_list.h View 1 2 3 4 5 6 7 8 3 chunks +31 lines, -9 lines 0 comments Download
M net/dns/async_host_resolver.h View 1 2 3 4 5 6 7 8 7 chunks +12 lines, -12 lines 0 comments Download
M net/dns/async_host_resolver.cc View 1 2 3 4 5 6 7 10 chunks +30 lines, -28 lines 0 comments Download
M net/dns/async_host_resolver_unittest.cc View 1 2 3 4 5 6 7 8 10 chunks +73 lines, -49 lines 0 comments Download
M net/dns/dns_client.h View 1 2 3 4 1 chunk +0 lines, -90 lines 0 comments Download
M net/dns/dns_client.cc View 1 2 3 4 1 chunk +0 lines, -91 lines 0 comments Download
M net/dns/dns_client_unittest.cc View 1 2 3 4 1 chunk +0 lines, -311 lines 0 comments Download
M net/dns/dns_config_service.h View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -4 lines 0 comments Download
M net/dns/dns_config_service_win.cc View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -1 line 0 comments Download
M net/dns/dns_protocol.h View 1 2 3 4 5 6 7 8 3 chunks +9 lines, -2 lines 0 comments Download
M net/dns/dns_query.cc View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -2 lines 0 comments Download
M net/dns/dns_response.h View 1 2 3 4 5 6 7 8 4 chunks +21 lines, -6 lines 0 comments Download
M net/dns/dns_response.cc View 1 2 3 4 5 6 7 8 4 chunks +35 lines, -6 lines 0 comments Download
M net/dns/dns_response_unittest.cc View 1 2 3 4 5 1 chunk +12 lines, -2 lines 0 comments Download
M net/dns/dns_session.h View 1 2 3 4 5 6 7 8 3 chunks +11 lines, -11 lines 0 comments Download
M net/dns/dns_session.cc View 1 2 3 4 5 6 7 8 2 chunks +8 lines, -8 lines 0 comments Download
M net/dns/dns_test_util.h View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -19 lines 0 comments Download
D net/dns/dns_test_util.cc View 1 2 3 4 5 1 chunk +0 lines, -35 lines 0 comments Download
M net/dns/dns_transaction.h View 1 2 3 4 5 6 7 8 1 chunk +56 lines, -81 lines 0 comments Download
D net/dns/dns_transaction.cc View 1 2 3 4 5 6 7 8 2 chunks +454 lines, -201 lines 0 comments Download
M net/dns/dns_transaction_unittest.cc View 1 2 3 4 5 6 7 8 9 2 chunks +547 lines, -173 lines 0 comments Download
M net/net.gyp View 1 2 3 4 5 6 7 3 chunks +0 lines, -4 lines 0 comments Download

Messages

Total messages: 24 (0 generated)
szym
First draft. Probably does not even compile yet. No tests for suffix search and server ...
8 years, 11 months ago (2012-01-12 00:14:09 UTC) #1
szym
I'm mostly done with the implementation. I'll work on dns_client_unittests.cc now to test timeouts, server ...
8 years, 11 months ago (2012-01-12 19:09:58 UTC) #2
cbentzel
This CL is bigger than I want to tackle tonight, will get to it first ...
8 years, 11 months ago (2012-01-13 01:17:20 UTC) #3
cbentzel
I didn't make it all the way through, thought I'd send some initial comments. The ...
8 years, 11 months ago (2012-01-13 13:39:54 UTC) #4
szym
Thanks for the review. I'll move back to DnsTransaction::Start. In that case it does make ...
8 years, 11 months ago (2012-01-13 15:43:40 UTC) #5
mmenke
Bunch of fairly minor comments. Others may disagree, but I find it much easier to ...
8 years, 11 months ago (2012-01-13 16:44:37 UTC) #6
mmenke
http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc File net/dns/dns_client.cc (right): http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc#newcode405 net/dns/dns_client.cc:405: NetLog::TYPE_DNS_TRANSACTION_QUERY, Where do you log the corresponding end event?
8 years, 11 months ago (2012-01-13 17:16:24 UTC) #7
szym
http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc File net/dns/dns_client.cc (right): http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc#newcode380 net/dns/dns_client.cc:380: new NetLogSourceParameter("socket", socket->NetLog().source()))); On 2012/01/13 16:44:37, Matt Menke wrote: ...
8 years, 11 months ago (2012-01-13 17:17:42 UTC) #8
mmenke
http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc File net/dns/dns_client.cc (right): http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc#newcode380 net/dns/dns_client.cc:380: new NetLogSourceParameter("socket", socket->NetLog().source()))); On 2012/01/13 17:17:42, szym wrote: > ...
8 years, 11 months ago (2012-01-13 17:22:58 UTC) #9
cbentzel
http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc File net/dns/dns_client.cc (right): http://codereview.chromium.org/9190031/diff/4023/net/dns/dns_client.cc#newcode269 net/dns/dns_client.cc:269: int rv = PrepareSearch(); On 2012/01/13 15:43:40, szym wrote: ...
8 years, 11 months ago (2012-01-13 18:12:59 UTC) #10
szym
Renamed DnsClient to DnsTransactionFactory and responded to most of the review. I'll move dns_client to ...
8 years, 11 months ago (2012-01-13 20:06:17 UTC) #11
cbentzel
This is a really nice change. I like how the delayed-response-after-retry is handled. I have ...
8 years, 11 months ago (2012-01-13 22:17:25 UTC) #12
szym
As usual, commenting only on the things that need commenting. I'll fix the rest. http://codereview.chromium.org/9190031/diff/14003/net/dns/dns_client.h ...
8 years, 11 months ago (2012-01-13 22:32:44 UTC) #13
szym
Still working on tests. http://codereview.chromium.org/9190031/diff/12005/net/dns/dns_response.cc File net/dns/dns_response.cc (right): http://codereview.chromium.org/9190031/diff/12005/net/dns/dns_response.cc#newcode207 net/dns/dns_response.cc:207: return DNSDomainToString(qname()); On 2012/01/13 22:17:25, ...
8 years, 11 months ago (2012-01-17 15:38:25 UTC) #14
szym
A complete suite of tests. http://codereview.chromium.org/9251019/ needs to be committed first to remove ref-counting from ...
8 years, 11 months ago (2012-01-19 16:35:46 UTC) #15
mmenke
http://codereview.chromium.org/9190031/diff/3002/net/dns/async_host_resolver.cc File net/dns/async_host_resolver.cc (right): http://codereview.chromium.org/9190031/diff/3002/net/dns/async_host_resolver.cc#newcode431 net/dns/async_host_resolver.cc:431: scoped_ptr<DnsTransaction> dns_req = client_->CreateTransaction( nit: "scoped_ptr<DnsTransaction> dns_req(client_...);" is preferred. ...
8 years, 11 months ago (2012-01-19 17:24:47 UTC) #16
szym
Thanks for review. This CL is still blocked on http://codereview.chromium.org/9251019/ http://codereview.chromium.org/9190031/diff/3002/net/dns/async_host_resolver_unittest.cc File net/dns/async_host_resolver_unittest.cc (right): http://codereview.chromium.org/9190031/diff/3002/net/dns/async_host_resolver_unittest.cc#newcode124 ...
8 years, 11 months ago (2012-01-20 19:38:27 UTC) #17
cbentzel
LGTM http://codereview.chromium.org/9190031/diff/32001/net/dns/async_host_resolver_unittest.cc File net/dns/async_host_resolver_unittest.cc (right): http://codereview.chromium.org/9190031/diff/32001/net/dns/async_host_resolver_unittest.cc#newcode52 net/dns/async_host_resolver_unittest.cc:52: public base::SupportsWeakPtr<MockDnsTransactionFactory> { Nit: maybe just indent by ...
8 years, 11 months ago (2012-01-21 03:41:16 UTC) #18
mmenke
LGTM http://codereview.chromium.org/9190031/diff/32001/net/dns/async_host_resolver_unittest.cc File net/dns/async_host_resolver_unittest.cc (right): http://codereview.chromium.org/9190031/diff/32001/net/dns/async_host_resolver_unittest.cc#newcode56 net/dns/async_host_resolver_unittest.cc:56: class MockRequest : public DnsTransaction, nit: Might want ...
8 years, 11 months ago (2012-01-24 18:27:00 UTC) #19
szym
Thanks for the review. http://codereview.chromium.org/9190031/diff/32001/net/dns/dns_transaction_unittest.cc File net/dns/dns_transaction_unittest.cc (right): http://codereview.chromium.org/9190031/diff/32001/net/dns/dns_transaction_unittest.cc#newcode38 net/dns/dns_transaction_unittest.cc:38: class TestUDPClientSocket : public MockUDPClientSocket ...
8 years, 11 months ago (2012-01-25 18:04:33 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/szym@chromium.org/9190031/46003
8 years, 11 months ago (2012-01-25 18:06:51 UTC) #21
commit-bot: I haz the power
Try job failure for 9190031-46003 (retry) on win_rel for step "ui_tests". It's a second try, ...
8 years, 11 months ago (2012-01-25 20:06:29 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/szym@chromium.org/9190031/46003
8 years, 11 months ago (2012-01-25 21:23:18 UTC) #23
commit-bot: I haz the power
8 years, 11 months ago (2012-01-26 00:04:01 UTC) #24
Change committed as 119146

Powered by Google App Engine
This is Rietveld 408576698