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

Issue 456063002: ExtensionUpdater: Abstract ExtensionDownloader creation (Closed)

Created:
6 years, 4 months ago by Ken Rockot(use gerrit already)
Modified:
6 years, 4 months ago
Reviewers:
Yoyo Zhou
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, extensions-reviews_chromium.org
Project:
chromium
Visibility:
Public.

Description

ExtensionUpdater: Abstract ExtensionDownloader creation ExtensionUpdater likes to create and destroy ExtensionDownloader instances as needed. This is fine, but it means duplicating efforts any time new dependencies need to be injected into ExtensionDownloader, because then they also need to be injected into ExtensionUpdater. This CL adds a factory callback to ExtensionUpdater's constructor so that ExtensionUpdater creators can opaquely inform the instance about how it should construct new ExtensionDownloaders. This also reverts the change to ExtensionDownloader's constructor which took an (optionally NULL) IdentityProvider; this can now instead be attached to new ExtensionDownloader instances by the factory responsible for their construction via the SetWebstoreIdentityProvider method. ExtensionService provides an example of this. BUG=398671 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=288964

Patch Set 1 : #

Total comments: 10

Patch Set 2 : comments and some cleanup #

Unified diffs Side-by-side diffs Delta from patch set Stats (+171 lines, -109 lines) Patch
M chrome/browser/chromeos/extensions/external_cache.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/extensions/extension_service.h View 1 2 chunks +6 lines, -0 lines 0 comments Download
M chrome/browser/extensions/extension_service.cc View 1 4 chunks +19 lines, -1 line 0 comments Download
M chrome/browser/extensions/updater/extension_downloader.h View 4 chunks +14 lines, -7 lines 0 comments Download
M chrome/browser/extensions/updater/extension_downloader.cc View 1 5 chunks +9 lines, -6 lines 0 comments Download
M chrome/browser/extensions/updater/extension_updater.h View 1 7 chunks +12 lines, -7 lines 0 comments Download
M chrome/browser/extensions/updater/extension_updater.cc View 1 5 chunks +10 lines, -10 lines 0 comments Download
M chrome/browser/extensions/updater/extension_updater_unittest.cc View 1 26 chunks +100 lines, -77 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
Ken Rockot(use gerrit already)
Yoyo, could you please take a look?
6 years, 4 months ago (2014-08-09 00:17:26 UTC) #1
Yoyo Zhou
LGTM with nits https://chromiumcodereview.appspot.com/456063002/diff/20001/chrome/browser/extensions/extension_service.cc File chrome/browser/extensions/extension_service.cc (right): https://chromiumcodereview.appspot.com/456063002/diff/20001/chrome/browser/extensions/extension_service.cc#newcode334 chrome/browser/extensions/extension_service.cc:334: base::Unretained(this)))); Why not use weak pointers? ...
6 years, 4 months ago (2014-08-11 23:19:28 UTC) #2
Ken Rockot(use gerrit already)
Thanks https://codereview.chromium.org/456063002/diff/20001/chrome/browser/extensions/extension_service.cc File chrome/browser/extensions/extension_service.cc (right): https://codereview.chromium.org/456063002/diff/20001/chrome/browser/extensions/extension_service.cc#newcode334 chrome/browser/extensions/extension_service.cc:334: base::Unretained(this)))); On 2014/08/11 23:19:28, Yoyo Zhou wrote: > ...
6 years, 4 months ago (2014-08-11 23:48:25 UTC) #3
Ken Rockot(use gerrit already)
The CQ bit was checked by rockot@chromium.org
6 years, 4 months ago (2014-08-12 00:59:47 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rockot@chromium.org/456063002/40001
6 years, 4 months ago (2014-08-12 01:04:33 UTC) #5
commit-bot: I haz the power
6 years, 4 months ago (2014-08-12 14:48:47 UTC) #6
Message was sent while issue was closed.
Change committed as 288964

Powered by Google App Engine
This is Rietveld 408576698