0
Commit Graph

25 Commits

Author SHA1 Message Date
Avi Drissman
4e1b7bc33d Update copyright headers in content/
The methodology used to generate this CL is documented in
https://crbug.com/1098010#c34.

No-Try: true
No-Presubmit: true
Bug: 1098010
Change-Id: I8c0f009d16350271f07d8e5e561085822cc9dd27
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3895935
Owners-Override: Avi Drissman <avi@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
Auto-Submit: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1047456}
2022-09-15 14:03:50 +00:00
Lei Zhang
ed9be3a428 Remove many unneeded CONTENT_EXPORT entries.
Many classes within content don't need CONTENT_EXPORT because they are
not in content/public and they are not directly used from tests.

Change-Id: I22696b3840ab7a89371184e866b05d0b4980e7dc
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3288753
Auto-Submit: Lei Zhang <thestig@chromium.org>
Commit-Queue: Avi Drissman <avi@chromium.org>
Reviewed-by: Avi Drissman <avi@chromium.org>
Owners-Override: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#942828}
2021-11-17 22:01:18 +00:00
John Abd-El-Malek
76ad70a295 Reland "Move WebUI code to run on the UI thread."
This reverts commit 8f6d952389.

Per analysis of all the waterfall bots that run this chrome_all_tast_tests, this doesn't affect the flakiness. Details in
https://bugs.chromium.org/p/chromium/issues/detail?id=1082326#c51

Original change's description:
> Revert moving WebUI code to run on the UI thread as there are still PFQ flakes.
>
> Revert "Reland "Move WebUI code to run on the UI thread only.""
>
> This reverts commit 52fd322ec1.
>
> Revert "Reland "Remove InstantIOContext since it's not needed anymore.""
>
> This reverts commit 6360b9fdb0.
>
> Revert "Add extra thread hops in WebUI code on ChromeOS to simulate old timing."
>
> This reverts commit dbb65740f2.
>
> TBR=jennyz@chromium.org
>
> Bug: 1082326, 1062873
> Change-Id: Ic6e6d1cce833c9927ac80ceada5e682c3d120553
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2203707
> Reviewed-by: John Abd-El-Malek <jam@chromium.org>
> Commit-Queue: John Abd-El-Malek <jam@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#769199}

TBR=jennyz@chromium.org

Bug: 1082326, 1062873
Change-Id: I577980c0240321a1f39b72f70fc63556c2f82cac
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2203411
Commit-Queue: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Jenny Zhang <jennyz@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#769725}
2020-05-18 16:08:12 +00:00
John Abd-El-Malek
8f6d952389 Revert moving WebUI code to run on the UI thread as there are still PFQ flakes.
Revert "Reland "Move WebUI code to run on the UI thread only.""

This reverts commit 52fd322ec1.

Revert "Reland "Remove InstantIOContext since it's not needed anymore.""

This reverts commit 6360b9fdb0.

Revert "Add extra thread hops in WebUI code on ChromeOS to simulate old timing."

This reverts commit dbb65740f2.

TBR=jennyz@chromium.org

Bug: 1082326, 1062873
Change-Id: Ic6e6d1cce833c9927ac80ceada5e682c3d120553
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2203707
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Commit-Queue: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#769199}
2020-05-15 08:44:17 +00:00
John Abd-El-Malek
52fd322ec1 Reland "Move WebUI code to run on the UI thread only."
This is a reland of 2dd9b658bb. There's no change, the fix was in different code in r768065.

TBR=nasko@chromium.org

Original change's description:
> Move WebUI code to run on the UI thread only.
>
> The optimization to run it on the IO thread was for the non-network service path. We can now simplify this.
>
> InstantIOContext can be removed, I'll leave that for a follow-up as this is already big.
>
> Bug: 908955,1062873
> Change-Id: Ia209d22575f49159227e49accf249dccb4fbaffe
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2190744
> Reviewed-by: Nasko Oskov <nasko@chromium.org>
> Commit-Queue: John Abd-El-Malek <jam@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#767182}

Bug: 908955, 1062873
Change-Id: Iae51e1c9b17a9c9d68bdfebd3a07387f34070339
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2197500
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Commit-Queue: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#768133}
2020-05-13 04:16:27 +00:00
Fergus Dall
24baf18ad1 Revert "Move WebUI code to run on the UI thread only."
This reverts commit 2dd9b658bb.

Reason for revert: Broke test CrostiniManagerRestartTest.RestartDelayAndSuccessWhenVmStopping on ASAN and MSAN CrOS bots.

First failures:
https://ci.chromium.org/p/chromium/builders/ci/Linux%20Chromium%20OS%20ASan%20LSan%20Tests%20%281%29/37623
https://ci.chromium.org/p/chromium/builders/ci/Linux%20ChromiumOS%20MSan%20Tests/19081

Bisection pinpoints this as the bad CL

Original change's description:
> Move WebUI code to run on the UI thread only.
> 
> The optimization to run it on the IO thread was for the non-network service path. We can now simplify this.
> 
> InstantIOContext can be removed, I'll leave that for a follow-up as this is already big.
> 
> Bug: 908955,1062873
> Change-Id: Ia209d22575f49159227e49accf249dccb4fbaffe
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2190744
> Reviewed-by: Nasko Oskov <nasko@chromium.org>
> Commit-Queue: John Abd-El-Malek <jam@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#767182}

TBR=nasko@chromium.org,jam@chromium.org

Change-Id: I35de3a275f1d2a626140670e01021985c6b0be0a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 908955, 1062873, 1081232
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2195423
Commit-Queue: Fergus Dall <sidereal@google.com>
Reviewed-by: Fergus Dall <sidereal@google.com>
Cr-Commit-Position: refs/heads/master@{#767602}
2020-05-12 00:41:50 +00:00
John Abd-El-Malek
2dd9b658bb Move WebUI code to run on the UI thread only.
The optimization to run it on the IO thread was for the non-network service path. We can now simplify this.

InstantIOContext can be removed, I'll leave that for a follow-up as this is already big.

Bug: 908955,1062873
Change-Id: Ia209d22575f49159227e49accf249dccb4fbaffe
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2190744
Reviewed-by: Nasko Oskov <nasko@chromium.org>
Commit-Queue: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#767182}
2020-05-11 05:08:57 +00:00
Marijn Kruisselbrink
71783b53e1 [Blobs] Remove no longer used method that looked up blobs by UUID.
Bug: 740744
Change-Id: Ic22655d70695ca04ab30300293ecd24a92dab3ec
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1867295
Reviewed-by: Avi Drissman <avi@chromium.org>
Reviewed-by: Daniel Murphy <dmurph@chromium.org>
Commit-Queue: Marijn Kruisselbrink <mek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#708326}
2019-10-22 20:30:38 +00:00
John Abd-El-Malek
8d5d3a3dec Remove the streams code as it's no longer used.
Bug: 934009
Change-Id: Idcf36e666b12cb0029f6c341c868ccf4e4cba450
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1639597
Commit-Queue: Yutaka Hirano <yhirano@chromium.org>
Commit-Queue: Sam McNally <sammc@chromium.org>
Auto-Submit: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Yutaka Hirano <yhirano@chromium.org>
Reviewed-by: Sam McNally <sammc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#665444}
2019-06-03 02:38:49 +00:00
horo
d556043ea4 [ServiceWorker] Make Stream support in ServiceWorkerURLRequestJob
In ServiceWorkerURLRequestJob::DidDispatchFetchEvent(), if response.stream_url of ServiceWorkerHostMsg_FetchEventFinished is set, ServiceWorkerURLRequestJob starts reading the body of the response from the stream instead of the blob.

But the stream may not be registered yet.
It is because ServiceWorkerHostMsg_FetchEventFinished is sent from the worker thread but StreamHostMsg_StartBuilding which triggers the stream registration is sent from the main thread of the ServiceWorker process.
So if ServiceWorkerURLRequestJob can't get the stream in DidDispatchFetchEvent(), call StreamRegistry::SetRegisterObserver() to receive the stream registration event.

When ServiceWorkerURLRequestJob successfuly gets the stream, it starts reading the stream.
The codes for reading the stream is almost same as the codes in StreamURLRequestJob.

This change depends on these changes:
  https://codereview.chromium.org/760823002
  https://codereview.chromium.org/759823003

BUG=436424

Review URL: https://codereview.chromium.org/759203002

Cr-Commit-Position: refs/heads/master@{#308059}
2014-12-12 06:20:32 +00:00
wjmaclean
caa7d6d94e Migrate HostZoomMap to live in StoragePartition.
This CL changes the persistence of host zoom levels to be on
a per-storage-partition basis, as opposed to (the current)
per-profile basis. This is needed to allow WebView content
(withing apps) to keep their zoom levels independent of those
in the main browser window.

BUG=335317

Review URL: https://codereview.chromium.org/393133002

Cr-Commit-Position: refs/heads/master@{#303841}
2014-11-12 16:42:27 +00:00
zork@chromium.org
bb85a8c450 Reland r187230: Implement the Stream registry in content
This fixes the memory leaks introduced by the original CL.

BUG=171585


Review URL: https://chromiumcodereview.appspot.com/12637006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@187777 0039d316-1c4b-4281-b951-d872f2087c98
2013-03-13 04:34:19 +00:00
zork@chromium.org
e19a0936b5 Revert 187230
> Implement the Stream registry in content
> 
> This is the first part of the content side of the Streams api.
> See:
> https://bugs.webkit.org/show_bug.cgi?id=110194
> https://dvcs.w3.org/hg/streams-api/raw-file/tip/Overview.htm
> 
> BUG=171585
> 
> 
> Review URL: https://chromiumcodereview.appspot.com/12335087

TBR=zork@chromium.org
Review URL: https://codereview.chromium.org/12611018

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@187274 0039d316-1c4b-4281-b951-d872f2087c98
2013-03-11 11:23:25 +00:00
zork@chromium.org
2ebbb66ffd Implement the Stream registry in content
This is the first part of the content side of the Streams api.
See:
https://bugs.webkit.org/show_bug.cgi?id=110194
https://dvcs.w3.org/hg/streams-api/raw-file/tip/Overview.htm

BUG=171585


Review URL: https://chromiumcodereview.appspot.com/12335087

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@187230 0039d316-1c4b-4281-b951-d872f2087c98
2013-03-11 03:43:16 +00:00
jam@chromium.org
5bf1646f54 Clean up of url data manager classes in content: move URLDataSourceImpl to its own file, move all the code to the content namespace, and remove the "Chrome" prefix from classes.
TBR=scottmg
BUG=169170
Review URL: https://codereview.chromium.org/12093012

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@179096 0039d316-1c4b-4281-b951-d872f2087c98
2013-01-28 03:57:02 +00:00
jam@chromium.org
33c1c26ae2 Move core url data manager classes to content.
BUG=169170
Review URL: https://codereview.chromium.org/12049052

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@178663 0039d316-1c4b-4281-b951-d872f2087c98
2013-01-24 21:56:26 +00:00
jam@chromium.org
c2ab420aa5 Move fileapi and dom_storage directories into the content namespace.
Review URL: https://codereview.chromium.org/11269010

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@163944 0039d316-1c4b-4281-b951-d872f2087c98
2012-10-24 22:54:46 +00:00
michaeln@chromium.org
55c0ecae62 AppCache and StoragePartition'ing
* Get rid of BrowserContext::GetAppCacheService and ResourceContext::GetAppCacheService as they've been replace by accessors on the StoragePartition and WorkerStoragePartition classes.

* Added a BrowsingContext::GetRequestContextForStoragePartition(id) accessor so the constellation of storage context + main request context can initialized properly. Implemented that method in chrome's Profile class in terms of the existing GetRequestContextForIsolatedApp(id) accessor.

* Hold references to the ChromeAppCacheService and ChromeBlobStorageContext inside of ResourceMessageFilter and provide accessors to them. These are for use by the ResourceDispatcherHost singleton which would otherwise not have enough context to get needed references to partitioned things.

* Widen the ResourceDispatcherHostDelegate::RequestBeginning method to also take an AppCacheService* parameter since that value can no longer be retrieved via the ResourceContext. Chrome's impl of this delegate interface needs that value to construct OfflineResourceThrottles.

* Poke at WorkerProcessHost to create ResourceMessageFilters and others to utlize the correct URLRequestContext so the right set of cookies are used in shared workers.

TBR=mihaip,sail,thakis
BUG=85121

Review URL: https://chromiumcodereview.appspot.com/10916132

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@156991 0039d316-1c4b-4281-b951-d872f2087c98
2012-09-15 05:12:34 +00:00
ajwong@chromium.org
7dc8935a75 Remove storage context accessors from ResourceContext.
ResourceContext is the IO thread projection of the Profile. Since one profile
may now have multiple StoragePartitions (and thus multiple storage contexts),
we need to remove these accessors. All code in the IO thread has enough
information to find their appropriate storage context objects without needing
to grab it through the ResourceContext.  The only users of the ResourceContext
storage context APIs are in worker_host classes.

As a result of this change, a number of APIs that previously just took 1
ResourceContext now need to take 4 additional objects. We could create a
StoragePartitionForIO class that parallels StoragePartition, but since the
API ugliness is purely limited to workers, the abstraction isn't worth its
weight.

BUG=85121


Review URL: https://chromiumcodereview.appspot.com/10885044

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@156126 0039d316-1c4b-4281-b951-d872f2087c98
2012-09-11 21:41:01 +00:00
jam@chromium.org
ff1e64e3fb Remove resource_request_info_impl.h dependency from chrome. This also makes blob/file system work in content based browsers.
I also moved the appcache/blob/cache developer urls to content so that they work in content_shell. This simplifies the Content API since the static blob/filesystem getters in ResourceContext are now not needed.

BUG=98716
Review URL: https://chromiumcodereview.appspot.com/9834039

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@128493 0039d316-1c4b-4281-b951-d872f2087c98
2012-03-23 15:21:51 +00:00
jam@chromium.org
7e26ac973e Fix race condition where the items on ResourceContext's UserData map were rewritten to the same value as they were read on the IO thread.
BUG=115678
Review URL: https://chromiumcodereview.appspot.com/9466031

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123794 0039d316-1c4b-4281-b951-d872f2087c98
2012-02-27 20:15:05 +00:00
jam@chromium.org
c1fff0754f Get rid of WebKitContext. Only two out of six HTML5 related objects were in it and it was just a glorified std::pair after the recent refactorings.
BUG=98716
Review URL: https://chromiumcodereview.appspot.com/9467016

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123588 0039d316-1c4b-4281-b951-d872f2087c98
2012-02-24 23:38:12 +00:00
erikwright@chromium.org
38ed59bd62 Fail gracefully if InitializeResourceContext ends up calling itself recursively.
BUG=None
TEST=chrome_frame_net_tests don't crash at shutdown (Note, they currently crash at startup or simply don't run without a few other patches applied - this fixes one of the crashes!).


Review URL: http://codereview.chromium.org/9443033

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123492 0039d316-1c4b-4281-b951-d872f2087c98
2012-02-24 17:08:24 +00:00
jam@chromium.org
5fe3713acc Move creation and ownership of HostZoomMap to content instead of having every embedder do this.
BUG=98716
Review URL: https://chromiumcodereview.appspot.com/9416070

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123002 0039d316-1c4b-4281-b951-d872f2087c98
2012-02-22 08:31:56 +00:00
jam@chromium.org
314c3e2d86 Remove getters for HTML5 related objects from the ResourceContext interface. Half of them weren't used by chrome, so they can be hidden from chrome. The rest were accessed by chrome, but we don't need every embedder to store this data on their ResourceContext implementation. Instead have content associate the data itself to simplify the work for embedders.
BUG=98716
Review URL: https://chromiumcodereview.appspot.com/9425026

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@122790 0039d316-1c4b-4281-b951-d872f2087c98
2012-02-21 03:57:42 +00:00