Title: [237949] trunk/Source/WebKit
- Revision
- 237949
- Author
- wilan...@apple.com
- Date
- 2018-11-07 16:15:59 -0800 (Wed, 07 Nov 2018)
Log Message
Resource Load Statistics: Enable cap on partitioned cache max age
https://bugs.webkit.org/show_bug.cgi?id=191395
<rdar://problem/45885977>
Reviewed by Chris Dumez.
This change does not bump the network cache revision number.
It's not needed since it was done just a week ago.
* UIProcess/ResourceLoadStatisticsMemoryStore.cpp:
(WebKit::ResourceLoadStatisticsMemoryStore::setCacheMaxAgeCap):
(WebKit::ResourceLoadStatisticsMemoryStore::updateCacheMaxAgeCap):
* UIProcess/ResourceLoadStatisticsMemoryStore.h:
* UIProcess/WebResourceLoadStatisticsStore.cpp:
(WebKit::WebResourceLoadStatisticsStore::didCreateNetworkProcess):
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (237948 => 237949)
--- trunk/Source/WebKit/ChangeLog 2018-11-08 00:10:20 UTC (rev 237948)
+++ trunk/Source/WebKit/ChangeLog 2018-11-08 00:15:59 UTC (rev 237949)
@@ -1,3 +1,21 @@
+2018-11-07 John Wilander <wilan...@apple.com>
+
+ Resource Load Statistics: Enable cap on partitioned cache max age
+ https://bugs.webkit.org/show_bug.cgi?id=191395
+ <rdar://problem/45885977>
+
+ Reviewed by Chris Dumez.
+
+ This change does not bump the network cache revision number.
+ It's not needed since it was done just a week ago.
+
+ * UIProcess/ResourceLoadStatisticsMemoryStore.cpp:
+ (WebKit::ResourceLoadStatisticsMemoryStore::setCacheMaxAgeCap):
+ (WebKit::ResourceLoadStatisticsMemoryStore::updateCacheMaxAgeCap):
+ * UIProcess/ResourceLoadStatisticsMemoryStore.h:
+ * UIProcess/WebResourceLoadStatisticsStore.cpp:
+ (WebKit::WebResourceLoadStatisticsStore::didCreateNetworkProcess):
+
2018-11-07 Daniel Bates <daba...@apple.com>
[iOS] Support deleting to the start of the line and to the end of the line
Modified: trunk/Source/WebKit/UIProcess/ResourceLoadStatisticsMemoryStore.cpp (237948 => 237949)
--- trunk/Source/WebKit/UIProcess/ResourceLoadStatisticsMemoryStore.cpp 2018-11-08 00:10:20 UTC (rev 237948)
+++ trunk/Source/WebKit/UIProcess/ResourceLoadStatisticsMemoryStore.cpp 2018-11-08 00:15:59 UTC (rev 237949)
@@ -835,7 +835,15 @@
ASSERT(!RunLoop::isMain());
ASSERT(seconds >= 0_s);
- RunLoop::main().dispatch([store = makeRef(m_store), seconds] () {
+ m_parameters.cacheMaxAgeCapTime = seconds;
+ updateCacheMaxAgeCap();
+}
+
+void ResourceLoadStatisticsMemoryStore::updateCacheMaxAgeCap()
+{
+ ASSERT(!RunLoop::isMain());
+
+ RunLoop::main().dispatch([store = makeRef(m_store), seconds = m_parameters.cacheMaxAgeCapTime] () {
store->setCacheMaxAgeCap(seconds, [] { });
});
}
Modified: trunk/Source/WebKit/UIProcess/ResourceLoadStatisticsMemoryStore.h (237948 => 237949)
--- trunk/Source/WebKit/UIProcess/ResourceLoadStatisticsMemoryStore.h 2018-11-08 00:10:20 UTC (rev 237948)
+++ trunk/Source/WebKit/UIProcess/ResourceLoadStatisticsMemoryStore.h 2018-11-08 00:15:59 UTC (rev 237949)
@@ -113,6 +113,7 @@
void setMinimumTimeBetweenDataRecordsRemoval(Seconds);
void setGrandfatheringTime(Seconds);
void setCacheMaxAgeCap(Seconds);
+ void updateCacheMaxAgeCap();
void setResourceLoadStatisticsDebugMode(bool);
bool isDebugModeEnabled() const { return m_debugModeEnabled; };
void setPrevalentResourceForDebugMode(const String& domain);
@@ -162,6 +163,7 @@
std::optional<Seconds> timeToLiveUserInteraction;
Seconds minimumTimeBetweenDataRecordsRemoval { 1_h };
Seconds grandfatheringTime { 24_h * 7 };
+ Seconds cacheMaxAgeCapTime { 24_h * 7 };
bool shouldNotifyPagesWhenDataRecordsWereScanned { false };
bool shouldClassifyResourcesBeforeDataRecordsRemoval { true };
bool shouldSubmitTelemetry { true };
Modified: trunk/Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.cpp (237948 => 237949)
--- trunk/Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.cpp 2018-11-08 00:10:20 UTC (rev 237948)
+++ trunk/Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.cpp 2018-11-08 00:15:59 UTC (rev 237949)
@@ -330,6 +330,7 @@
if (!m_memoryStore)
return;
m_memoryStore->updateCookieBlocking([]() { });
+ m_memoryStore->updateCacheMaxAgeCap();
});
#if ENABLE(RESOURCE_LOAD_STATISTICS)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes