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

Issue 2171743002: Do not persist HttpServerProperties to disk that often. (Closed)

Created:
4 years, 5 months ago by Bence
Modified:
4 years, 4 months ago
Reviewers:
Ryan Hamilton
CC:
chromium-reviews, cbentzel+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Do not persist HttpServerProperties to disk that often. Add some heuristics to SetAlternativeServices that prevents a ScheduleUpdatePrefsOnNetworkThread() call after each incoming Alt-Svc header, based on the time of the last update, and the expiration times of the current and new in-memory entries. (Note that the current in-memory entry might be different from the entry last persisted to disk.) Repeated requests to the same server typically result in identical Alt-Svc announcements, which become different when the max-age field (in seconds from now) gets converted into a base::Time expiration time. Alternative services do not need to be persisted to disk with every incoming Alt-Svc header if other fields (scheme, host, port) are identical. BUG=554643 Committed: https://crrev.com/4b91d834629c5b01ae73b58e33b7b63cedde871d Cr-Commit-Position: refs/heads/master@{#408273}

Patch Set 1 #

Total comments: 13

Patch Set 2 : Re: #7. #

Total comments: 2

Patch Set 3 : Rebase. #

Patch Set 4 : Re: #13. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+26 lines, -4 lines) Patch
M net/http/http_server_properties.h View 2 chunks +5 lines, -2 lines 0 comments Download
M net/http/http_server_properties_impl.cc View 1 2 3 1 chunk +21 lines, -2 lines 0 comments Download

Messages

Total messages: 24 (15 generated)
Bence
Ryan: PTAL. Thank you.
4 years, 5 months ago (2016-07-21 14:13:31 UTC) #6
Ryan Hamilton
https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc File net/http/http_server_properties_impl.cc (right): https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc#newcode412 net/http/http_server_properties_impl.cc:412: bool changed; I think you can simplify this slightly: ...
4 years, 5 months ago (2016-07-21 22:27:05 UTC) #7
Bence
PTAL. Thank you. https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc File net/http/http_server_properties_impl.cc (right): https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc#newcode412 net/http/http_server_properties_impl.cc:412: bool changed; On 2016/07/21 22:27:05, Ryan ...
4 years, 5 months ago (2016-07-22 16:28:55 UTC) #12
Ryan Hamilton
https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc File net/http/http_server_properties_impl.cc (right): https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc#newcode430 net/http/http_server_properties_impl.cc:430: new_time - now > 2 * (old_time - now)) ...
4 years, 5 months ago (2016-07-22 23:31:36 UTC) #13
Bence
PTAL. Thank you. https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc File net/http/http_server_properties_impl.cc (right): https://codereview.chromium.org/2171743002/diff/1/net/http/http_server_properties_impl.cc#newcode430 net/http/http_server_properties_impl.cc:430: new_time - now > 2 * ...
4 years, 4 months ago (2016-07-27 16:30:55 UTC) #18
Ryan Hamilton
lgtm Looks great!
4 years, 4 months ago (2016-07-27 23:31:49 UTC) #20
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/2171743002/60001
4 years, 4 months ago (2016-07-27 23:32:15 UTC) #21
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 4 months ago (2016-07-27 23:37:04 UTC) #22
commit-bot: I haz the power
4 years, 4 months ago (2016-07-27 23:39:22 UTC) #24
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/4b91d834629c5b01ae73b58e33b7b63cedde871d
Cr-Commit-Position: refs/heads/master@{#408273}

Powered by Google App Engine
This is Rietveld 408576698