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

Issue 11147026: Initial refactor to get profiles to propagate storage partition details. (Closed)

Created:
8 years, 2 months ago by nasko
Modified:
8 years, 1 month ago
CC:
chromium-reviews, cbentzel+watch_chromium.org, mihaip-chromium-reviews_chromium.org, jam, joi+watch-content_chromium.org, Aaron Boodman, darin-cc_chromium.org, rdsmith+dwatch_chromium.org
Visibility:
Public.

Description

For storage partitions to work properly, we need to know whether a storage partition is in-memory only and what directory it is supposed to live under. This information is currently not available on the IO thread, where we create the cookie store and HTTP cache. This CL is an the first step, aiming to to get profiles to propagate storage partition details from GetResourceContext* methods on the UI thread to the IO thread. BUG=145500, 138296 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=165057

Patch Set 1 : #

Patch Set 2 : #

Patch Set 3 : Moving from std::string to FilePath. #

Patch Set 4 : Fixing browser tag test and persistence. #

Patch Set 5 : Changing the hash function to work cross-platform. #

Patch Set 6 : Cleanup. #

Patch Set 7 : Changing bool param to pass by reference. #

Total comments: 27

Patch Set 8 : Changes based on Albert's review. #

Total comments: 8

Patch Set 9 : Removed macro and InMemory. #

Total comments: 14

Patch Set 10 : Replacing hash_map with std::map. #

Patch Set 11 : Ops, use functors. #

Patch Set 12 : Fixed the order in the gypi file. #

Total comments: 20

Patch Set 13 : Another round of fixes based on Albert's review. #

Patch Set 14 : Fixing Android's BrowserContext. #

Total comments: 30

Patch Set 15 : Fixes based on review feedback. #

Patch Set 16 : Added missing piece of the comment. #

Patch Set 17 : Syncing tree. #

Patch Set 18 : Missed a merging of removed variable. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+335 lines, -248 lines) Patch
M android_webview/browser/aw_browser_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -2 lines 0 comments Download
M android_webview/browser/aw_browser_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +4 lines, -2 lines 0 comments Download
M chrome/browser/extensions/data_deleter.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +9 lines, -5 lines 0 comments Download
M chrome/browser/extensions/web_view_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +6 lines, -4 lines 0 comments Download
M chrome/browser/net/chrome_url_request_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +4 lines, -3 lines 0 comments Download
M chrome/browser/net/chrome_url_request_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 10 chunks +23 lines, -20 lines 0 comments Download
M chrome/browser/profiles/off_the_record_profile_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +4 lines, -2 lines 0 comments Download
M chrome/browser/profiles/off_the_record_profile_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 4 chunks +8 lines, -24 lines 0 comments Download
M chrome/browser/profiles/off_the_record_profile_io_data.h View 1 2 3 4 5 6 7 8 9 10 3 chunks +12 lines, -8 lines 0 comments Download
M chrome/browser/profiles/off_the_record_profile_io_data.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +13 lines, -10 lines 0 comments Download
M chrome/browser/profiles/profile.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/profiles/profile_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +4 lines, -2 lines 0 comments Download
M chrome/browser/profiles/profile_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 3 chunks +27 lines, -40 lines 0 comments Download
M chrome/browser/profiles/profile_impl_io_data.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +13 lines, -9 lines 0 comments Download
M chrome/browser/profiles/profile_impl_io_data.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 11 chunks +45 lines, -41 lines 0 comments Download
M chrome/browser/profiles/profile_io_data.h View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +10 lines, -7 lines 0 comments Download
M chrome/browser/profiles/profile_io_data.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +12 lines, -10 lines 0 comments Download
A chrome/browser/profiles/storage_partition_descriptor.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +38 lines, -0 lines 0 comments Download
M chrome/browser/ui/webui/options/cookies_view_handler.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +32 lines, -20 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +1 line, -0 lines 0 comments Download
M chrome/test/base/testing_profile.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +4 lines, -2 lines 0 comments Download
M chrome/test/base/testing_profile.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 5 chunks +14 lines, -20 lines 0 comments Download
M content/browser/download/download_manager_impl_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +6 lines, -4 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.h View 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +4 lines, -0 lines 0 comments Download
M content/browser/storage_partition_impl_map.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +3 lines, -2 lines 0 comments Download
M content/public/browser/browser_context.h View 1 2 3 4 5 6 7 2 chunks +4 lines, -2 lines 0 comments Download
M content/public/browser/render_process_host.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +7 lines, -0 lines 0 comments Download
M content/public/test/mock_render_process_host.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +2 lines, -0 lines 0 comments Download
M content/public/test/mock_render_process_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +5 lines, -0 lines 0 comments Download
M content/public/test/test_browser_context.h View 1 2 3 4 5 6 7 1 chunk +4 lines, -2 lines 0 comments Download
M content/public/test/test_browser_context.cc View 1 2 3 4 5 6 7 2 chunks +4 lines, -2 lines 0 comments Download
M content/shell/shell_browser_context.h View 1 2 3 4 5 6 7 1 chunk +4 lines, -2 lines 0 comments Download
M content/shell/shell_browser_context.cc View 1 2 3 4 5 6 7 1 chunk +4 lines, -2 lines 0 comments Download

Messages

Total messages: 23 (0 generated)
nasko
Hey Albert, Can you review this change? It is the Profile side refactoring to get ...
8 years, 2 months ago (2012-10-18 18:33:45 UTC) #1
awong
Overall looks on the right track. My main thought is that we can use partition->GetRequestContext() ...
8 years, 2 months ago (2012-10-18 22:36:15 UTC) #2
nasko
Fixes based on Albert's review. https://codereview.chromium.org/11147026/diff/23003/chrome/browser/extensions/data_deleter.cc File chrome/browser/extensions/data_deleter.cc (right): https://codereview.chromium.org/11147026/diff/23003/chrome/browser/extensions/data_deleter.cc#newcode105 chrome/browser/extensions/data_deleter.cc:105: profile->GetRequestContextForStoragePartition( On 2012/10/18 22:36:15, ...
8 years, 2 months ago (2012-10-19 17:29:13 UTC) #3
awong
couple more comments, but looking pretty close. http://codereview.chromium.org/11147026/diff/23003/chrome/browser/profiles/profile_impl.cc File chrome/browser/profiles/profile_impl.cc (right): http://codereview.chromium.org/11147026/diff/23003/chrome/browser/profiles/profile_impl.cc#newcode768 chrome/browser/profiles/profile_impl.cc:768: content::StoragePartition* storage_partition ...
8 years, 2 months ago (2012-10-19 21:20:24 UTC) #4
nasko
Cleaned up the things mentioned in the last round. https://codereview.chromium.org/11147026/diff/38013/chrome/browser/profiles/off_the_record_profile_impl.cc File chrome/browser/profiles/off_the_record_profile_impl.cc (right): https://codereview.chromium.org/11147026/diff/38013/chrome/browser/profiles/off_the_record_profile_impl.cc#newcode285 chrome/browser/profiles/off_the_record_profile_impl.cc:285: ...
8 years, 2 months ago (2012-10-19 22:09:00 UTC) #5
awong
http://codereview.chromium.org/11147026/diff/36005/chrome/browser/extensions/data_deleter.cc File chrome/browser/extensions/data_deleter.cc (right): http://codereview.chromium.org/11147026/diff/36005/chrome/browser/extensions/data_deleter.cc#newcode101 chrome/browser/extensions/data_deleter.cc:101: content::SiteInstance* site = process_manager->GetSiteInstanceForURL(url); variable should be site_instance. Or ...
8 years, 2 months ago (2012-10-19 23:26:50 UTC) #6
nasko
https://codereview.chromium.org/11147026/diff/36005/chrome/browser/extensions/data_deleter.cc File chrome/browser/extensions/data_deleter.cc (right): https://codereview.chromium.org/11147026/diff/36005/chrome/browser/extensions/data_deleter.cc#newcode101 chrome/browser/extensions/data_deleter.cc:101: content::SiteInstance* site = process_manager->GetSiteInstanceForURL(url); On 2012/10/19 23:26:50, awong wrote: ...
8 years, 2 months ago (2012-10-19 23:55:16 UTC) #7
awong
Mostly nits. Getting close. http://codereview.chromium.org/11147026/diff/39054/chrome/browser/extensions/data_deleter.cc File chrome/browser/extensions/data_deleter.cc (right): http://codereview.chromium.org/11147026/diff/39054/chrome/browser/extensions/data_deleter.cc#newcode97 chrome/browser/extensions/data_deleter.cc:97: GURL url = Extension::GetBaseURLFromExtensionId(extension_id); const ...
8 years, 1 month ago (2012-10-29 23:37:40 UTC) #8
nasko
http://codereview.chromium.org/11147026/diff/39054/chrome/browser/extensions/data_deleter.cc File chrome/browser/extensions/data_deleter.cc (right): http://codereview.chromium.org/11147026/diff/39054/chrome/browser/extensions/data_deleter.cc#newcode97 chrome/browser/extensions/data_deleter.cc:97: GURL url = Extension::GetBaseURLFromExtensionId(extension_id); On 2012/10/29 23:37:40, awong wrote: ...
8 years, 1 month ago (2012-10-30 00:32:58 UTC) #9
awong
LGTM w/nit nit: Beef up the changelist description please :)
8 years, 1 month ago (2012-10-30 00:41:13 UTC) #10
nasko
Adding OWNERS reviewers. jhawkins@ - chrome/browser/ui/webui/options mihaip@ - chrome/browser/extensions mmenke@ - chrome/browser/{net|extensions} phajdan.jr@ - chrome/test ...
8 years, 1 month ago (2012-10-30 15:16:01 UTC) #11
joth
android_webview - lgtm
8 years, 1 month ago (2012-10-30 16:32:58 UTC) #12
James Hawkins
LGTM with nit. https://codereview.chromium.org/11147026/diff/52031/chrome/browser/ui/webui/options/cookies_view_handler.cc File chrome/browser/ui/webui/options/cookies_view_handler.cc (right): https://codereview.chromium.org/11147026/diff/52031/chrome/browser/ui/webui/options/cookies_view_handler.cc#newcode231 chrome/browser/ui/webui/options/cookies_view_handler.cc:231: if (service && process_manager) { Save ...
8 years, 1 month ago (2012-10-30 17:40:52 UTC) #13
Charlie Reis
Awesome. A few comments below. http://codereview.chromium.org/11147026/diff/52031/chrome/browser/extensions/web_view_browsertest.cc File chrome/browser/extensions/web_view_browsertest.cc (right): http://codereview.chromium.org/11147026/diff/52031/chrome/browser/extensions/web_view_browsertest.cc#newcode103 chrome/browser/extensions/web_view_browsertest.cc:103: // The default behavior ...
8 years, 1 month ago (2012-10-30 17:47:47 UTC) #14
Paweł Hajdan Jr.
chrome/test LGTM
8 years, 1 month ago (2012-10-30 17:48:44 UTC) #15
mmenke
LGTM. http://codereview.chromium.org/11147026/diff/52031/chrome/browser/net/chrome_url_request_context.h File chrome/browser/net/chrome_url_request_context.h (right): http://codereview.chromium.org/11147026/diff/52031/chrome/browser/net/chrome_url_request_context.h#newcode12 chrome/browser/net/chrome_url_request_context.h:12: #include "chrome/browser/profiles/storage_partition_descriptor.h" This shouldn't be needed, with the ...
8 years, 1 month ago (2012-10-30 18:27:15 UTC) #16
mmenke
Erm, that should be chrome/browser/net LGTM. On 2012/10/30 18:27:15, Matt Menke wrote: > LGTM. > ...
8 years, 1 month ago (2012-10-30 18:27:37 UTC) #17
nasko
https://codereview.chromium.org/11147026/diff/52031/chrome/browser/extensions/web_view_browsertest.cc File chrome/browser/extensions/web_view_browsertest.cc (right): https://codereview.chromium.org/11147026/diff/52031/chrome/browser/extensions/web_view_browsertest.cc#newcode103 chrome/browser/extensions/web_view_browsertest.cc:103: // The default behavior is to combine browser tags ...
8 years, 1 month ago (2012-10-30 19:55:25 UTC) #18
Charlie Reis
One nit below, and one question: Is the in_memory flag supposed to be used for ...
8 years, 1 month ago (2012-10-30 20:13:07 UTC) #19
nasko
Fixed the comment omission. All of the HTML5 storage is created when creating the StoragePartition ...
8 years, 1 month ago (2012-10-30 20:27:42 UTC) #20
Charlie Reis
On 2012/10/30 20:27:42, nasko wrote: > All of the HTML5 storage is created when creating ...
8 years, 1 month ago (2012-10-30 20:30:20 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/nasko@chromium.org/11147026/50004
8 years, 1 month ago (2012-10-30 21:17:13 UTC) #22
commit-bot: I haz the power
8 years, 1 month ago (2012-10-30 23:22:51 UTC) #23
Change committed as 165057

Powered by Google App Engine
This is Rietveld 408576698