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

Issue 16137008: Refactor net::NetLog to provide implementation of observer pattern, not just the interface. (Closed)

Created:
7 years, 6 months ago by kouhei (in TOK)
Modified:
7 years, 6 months ago
Reviewers:
eroman, mmenke, Wez
CC:
chromium-reviews, jamiewalch+watch_chromium.org, dcaiafa+watch_chromium.org, cbentzel+watch_chromium.org, hclam+watch_chromium.org, wez+watch_chromium.org, amit, sanjeevr, garykac+watch_chromium.org, eroman, rmsousa+watch_chromium.org, weitaosu+watch_chromium.org, alexeypa+watch_chromium.org, sergeyu+watch_chromium.org, lambroslambrou+watch_chromium.org, haraken, oshima
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Refactor net::NetLog to provide implementation of observer pattern, not just the interface. This would make use of net::NetLog::ThreadSafeObserver available from base/net, so custom NetLog implementations can focus on implementing OnAddEntry() without re-implementing all NetLog methods. The implementation of observer pattern was previously provided in ChromeNetLog. The contents of chrome_net_log_unittest are merged to net_log_unittest. TESTS=net_log_unittest BUG=None Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=204861 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=204946

Patch Set 1 #

Patch Set 2 : revert unwanted changes #

Patch Set 3 : revert more #

Total comments: 20

Patch Set 4 : #

Total comments: 24

Patch Set 5 : rebase / fix #

Patch Set 6 : #

Patch Set 7 : minimize diff #

Patch Set 8 : more minimize #

Patch Set 9 : avoid adding empty lines #

Patch Set 10 : private Observer #

Total comments: 14

Patch Set 11 : fix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+517 lines, -597 lines) Patch
M chrome/browser/net/chrome_net_log.h View 1 chunk +0 lines, -32 lines 0 comments Download
M chrome/browser/net/chrome_net_log.cc View 1 2 3 4 5 6 7 3 chunks +2 lines, -67 lines 0 comments Download
D chrome/browser/net/chrome_net_log_unittest.cc View 1 chunk +0 lines, -271 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 1 chunk +0 lines, -1 line 0 comments Download
M net/base/capturing_net_log.h View 1 2 3 4 5 6 7 8 9 2 chunks +36 lines, -27 lines 0 comments Download
M net/base/capturing_net_log.cc View 1 2 3 4 5 6 7 8 9 3 chunks +31 lines, -31 lines 0 comments Download
M net/base/net_log.h View 1 2 3 4 6 chunks +32 lines, -19 lines 0 comments Download
M net/base/net_log.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +80 lines, -18 lines 0 comments Download
M net/base/net_log_unittest.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +263 lines, -2 lines 0 comments Download
M net/tools/gdig/file_net_log.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +8 lines, -18 lines 0 comments Download
M net/tools/gdig/file_net_log.cc View 2 chunks +6 lines, -34 lines 0 comments Download
M net/tools/gdig/gdig.cc View 1 2 3 4 chunks +11 lines, -2 lines 0 comments Download
M net/tools/get_server_time/get_server_time.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +25 lines, -42 lines 0 comments Download
M remoting/host/vlog_net_log.h View 1 2 2 chunks +3 lines, -11 lines 0 comments Download
M remoting/host/vlog_net_log.cc View 2 chunks +20 lines, -22 lines 0 comments Download

Messages

Total messages: 23 (0 generated)
kouhei (in TOK)
mmenke: Would you take a look?
7 years, 6 months ago (2013-05-30 09:44:51 UTC) #1
mmenke
[+eroman]: FYI Some preliminary comments. This is a large enough CL that I want to ...
7 years, 6 months ago (2013-05-30 18:18:58 UTC) #2
kouhei (in TOK)
Thanks for your comments! https://codereview.chromium.org/16137008/diff/4001/chrome/browser/net/chrome_net_log.cc File chrome/browser/net/chrome_net_log.cc (right): https://codereview.chromium.org/16137008/diff/4001/chrome/browser/net/chrome_net_log.cc#newcode20 chrome/browser/net/chrome_net_log.cc:20: net::NetLog::LogLevel baseLogLevelFromCommandLine() { On 2013/05/30 ...
7 years, 6 months ago (2013-05-31 06:30:02 UTC) #3
mmenke
https://codereview.chromium.org/16137008/diff/12001/chrome/browser/net/chrome_net_log.cc File chrome/browser/net/chrome_net_log.cc (right): https://codereview.chromium.org/16137008/diff/12001/chrome/browser/net/chrome_net_log.cc#newcode43 chrome/browser/net/chrome_net_log.cc:43: : NetLog(GetBaseLogLevelFromCommandLine()), This constructor no longer exists, should use ...
7 years, 6 months ago (2013-06-03 14:27:09 UTC) #4
kouhei (in TOK)
Thanks for your comments! Updated patch. https://codereview.chromium.org/16137008/diff/12001/chrome/browser/net/chrome_net_log.cc File chrome/browser/net/chrome_net_log.cc (right): https://codereview.chromium.org/16137008/diff/12001/chrome/browser/net/chrome_net_log.cc#newcode43 chrome/browser/net/chrome_net_log.cc:43: : NetLog(GetBaseLogLevelFromCommandLine()), On ...
7 years, 6 months ago (2013-06-04 15:41:44 UTC) #5
mmenke
https://codereview.chromium.org/16137008/diff/12001/net/base/capturing_net_log.h File net/base/capturing_net_log.h (right): https://codereview.chromium.org/16137008/diff/12001/net/base/capturing_net_log.h#newcode99 net/base/capturing_net_log.h:99: // This is provided for compatilbility with old unittests. ...
7 years, 6 months ago (2013-06-04 16:55:47 UTC) #6
kouhei (in TOK)
https://codereview.chromium.org/16137008/diff/12001/net/base/capturing_net_log.h File net/base/capturing_net_log.h (right): https://codereview.chromium.org/16137008/diff/12001/net/base/capturing_net_log.h#newcode99 net/base/capturing_net_log.h:99: // This is provided for compatilbility with old unittests. ...
7 years, 6 months ago (2013-06-04 22:19:30 UTC) #7
mmenke
LGTM, thanks for the cleanup! https://codereview.chromium.org/16137008/diff/54001/net/base/net_log.cc File net/base/net_log.cc (right): https://codereview.chromium.org/16137008/diff/54001/net/base/net_log.cc#newcode238 net/base/net_log.cc:238: DCHECK(!observer->net_log_); optional nit: Suggest ...
7 years, 6 months ago (2013-06-05 16:22:14 UTC) #8
kouhei (in TOK)
Thanks for review! https://codereview.chromium.org/16137008/diff/54001/net/base/net_log.cc File net/base/net_log.cc (right): https://codereview.chromium.org/16137008/diff/54001/net/base/net_log.cc#newcode238 net/base/net_log.cc:238: DCHECK(!observer->net_log_); On 2013/06/05 16:22:14, mmenke wrote: ...
7 years, 6 months ago (2013-06-06 00:49:40 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kouhei@chromium.org/16137008/61001
7 years, 6 months ago (2013-06-06 00:50:30 UTC) #10
commit-bot: I haz the power
Retried try job too often on chromium_presubmit for step(s) presubmit http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=chromium_presubmit&number=7109
7 years, 6 months ago (2013-06-06 01:26:07 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kouhei@chromium.org/16137008/61001
7 years, 6 months ago (2013-06-06 22:37:40 UTC) #12
commit-bot: I haz the power
Retried try job too often on chromium_presubmit for step(s) presubmit http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=chromium_presubmit&number=7435
7 years, 6 months ago (2013-06-07 00:05:10 UTC) #13
mmenke
You need a signoff from an owner of remoting/host/vlog_net_log.h.
7 years, 6 months ago (2013-06-07 00:26:38 UTC) #14
Wez
lgtm
7 years, 6 months ago (2013-06-07 00:34:13 UTC) #15
kouhei (in TOK)
Thank you for pointing it out. On 2013/06/07 00:34:13, Wez wrote: > lgtm Wez: Thanks ...
7 years, 6 months ago (2013-06-07 14:54:19 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kouhei@chromium.org/16137008/61001
7 years, 6 months ago (2013-06-07 14:54:42 UTC) #17
commit-bot: I haz the power
Change committed as 204861
7 years, 6 months ago (2013-06-07 17:04:28 UTC) #18
kouhei (in TOK)
On 2013/06/07 17:04:28, I haz the power (commit-bot) wrote: > Change committed as 204861 reverted ...
7 years, 6 months ago (2013-06-07 19:32:52 UTC) #19
mmenke
On 2013/06/07 19:32:52, kouhei wrote: > On 2013/06/07 17:04:28, I haz the power (commit-bot) wrote: ...
7 years, 6 months ago (2013-06-07 20:21:51 UTC) #20
kouhei (in TOK)
I am re-committing this CL. I checked the leak report, but it seems it's unrelated ...
7 years, 6 months ago (2013-06-07 21:50:16 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kouhei@chromium.org/16137008/61001
7 years, 6 months ago (2013-06-07 21:51:29 UTC) #22
commit-bot: I haz the power
7 years, 6 months ago (2013-06-07 21:59:09 UTC) #23
Message was sent while issue was closed.
Change committed as 204946

Powered by Google App Engine
This is Rietveld 408576698