Resource Load Statistics: Add clearing of storage access to WebResourceLoadStatistics...
authorwilander@apple.com <wilander@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Mar 2018 05:05:36 +0000 (05:05 +0000)
committerwilander@apple.com <wilander@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Mar 2018 05:05:36 +0000 (05:05 +0000)
commit79c90f340e7eddb5ac052e6c1126eb41b3473865
treeb0161e26c8e50f066ecbca2a5c8ddc2128da7282
parentfc997be1093378adeb45dfdbaab18eef47266fc3
Resource Load Statistics: Add clearing of storage access to WebResourceLoadStatisticsStore::clearInMemory()
https://bugs.webkit.org/show_bug.cgi?id=183641
<rdar://problem/38469497>

Reviewed by Brent Fulgham and Chris Dumez.

Source/WebCore:

No new tests. This change is to stabilize existing layout tests.
See Ryan Haddad's comment in https://bugs.webkit.org/show_bug.cgi?id=183620.

* platform/network/NetworkStorageSession.h:
* platform/network/cf/NetworkStorageSessionCFNet.cpp:
(WebCore::NetworkStorageSession::removeAllStorageAccess):
    New function to clear out all storage access entries.

Source/WebKit:

This change is to stabilize existing layout tests by removing
all storage access entries on a call to
WebResourceLoadStatisticsStore::clearInMemory().
See Ryan Haddad's comment in https://bugs.webkit.org/show_bug.cgi?id=183620.

Almost all of the code changes are piping to get this
call from the WebResourceLoadStatisticsStore to
WebCore::NetworkStorageSession where entries reside.

* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::removeAllStorageAccess):
* NetworkProcess/NetworkProcess.h:
* NetworkProcess/NetworkProcess.messages.in:
* UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::removeAllStorageAccess):
* UIProcess/Network/NetworkProcessProxy.h:
* UIProcess/WebResourceLoadStatisticsStore.cpp:
(WebKit::WebResourceLoadStatisticsStore::WebResourceLoadStatisticsStore):
(WebKit::WebResourceLoadStatisticsStore::removeAllStorageAccess):
(WebKit::WebResourceLoadStatisticsStore::clearInMemory):
    Now also clears all storage access entries in the network process.
* UIProcess/WebResourceLoadStatisticsStore.h:
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::removeAllStorageAccessHandler):
(WebKit::WebsiteDataStore::enableResourceLoadStatisticsAndSetTestingCallback):
* UIProcess/WebsiteData/WebsiteDataStore.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@229619 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
Source/WebCore/ChangeLog
Source/WebCore/platform/network/NetworkStorageSession.h
Source/WebCore/platform/network/cf/NetworkStorageSessionCFNet.cpp
Source/WebKit/ChangeLog
Source/WebKit/NetworkProcess/NetworkProcess.cpp
Source/WebKit/NetworkProcess/NetworkProcess.h
Source/WebKit/NetworkProcess/NetworkProcess.messages.in
Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp
Source/WebKit/UIProcess/Network/NetworkProcessProxy.h
Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.cpp
Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.h
Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h