Commit fc7e8a34 authored by Ben Kelly's avatar Ben Kelly Committed by Commit Bot

Blob: Cap DataPipes at 2MB by default.

This CL increases the blob DataPipe cap from 512kb to 2MB to improve
performance.

Trials show a 12% progression at P95 when reading the body from a
cache_storage response provided to a subresource service worker
FetchEvent.  A partner site showed a 5% progression at P95 in core
css stylesheet load times.

Bug: 1010199
Change-Id: I040cadc1d6d7c081b242f72ad286a2f942b0a53f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1859839Reviewed-by: default avatarBrian White <bcwhite@chromium.org>
Reviewed-by: default avatarMarijn Kruisselbrink <mek@chromium.org>
Commit-Queue: Ben Kelly <wanderview@chromium.org>
Cr-Commit-Position: refs/heads/master@{#710783}
parent 764753a4
......@@ -350,7 +350,7 @@ TEST_F(ServiceWorkerInstalledScriptsSenderTest, FailedToSendBody) {
TEST_F(ServiceWorkerInstalledScriptsSenderTest, FailedToSendMetaData) {
const GURL kMainScriptURL = version()->script_url();
std::string long_meta_data = "I'm the meta data!";
long_meta_data.resize(1E6, '!');
long_meta_data.resize(3E6, '!');
std::map<GURL, ExpectedScriptInfo> kExpectedScriptInfoMap = {
{kMainScriptURL,
{1,
......
......@@ -1345,28 +1345,6 @@
]
}
],
"BlobDataPipeTuning": [
{
"platforms": [
"android",
"chromeos",
"linux",
"mac",
"windows"
],
"experiments": [
{
"name": "Enabled_2MB_v1",
"params": {
"capacity_bytes": "2097152"
},
"enable_features": [
"BlobDataPipeTuning"
]
}
]
}
],
"BlockPromptsIfIgnoredOften": [
{
"platforms": [
......
......@@ -21,7 +21,9 @@ const base::Feature kBlobDataPipeTuningFeature{
"BlobDataPipeTuning", base::FEATURE_DISABLED_BY_DEFAULT};
constexpr int kBlobMinDataPipeCapacity = 1024;
constexpr int kBlobDefaultDataPipeCapacity = 512 * 1024;
// The 2MB limit was selected via a finch trial.
constexpr int kBlobDefaultDataPipeCapacity = 2 * 1024 * 1024;
constexpr base::FeatureParam<int> kBlobDataPipeCapacity{
&kBlobDataPipeTuningFeature, "capacity_bytes",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment