Changeset 243723 in webkit
- Timestamp:
- Apr 1, 2019, 4:54:14 PM (7 years ago)
- Location:
- tags/Safari-608.1.13.4
- Files:
-
- 3 added
- 1 deleted
- 20 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/http/tests/storageAccess/deny-storage-access-under-opener-expected.txt (modified) (1 diff)
-
LayoutTests/http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-expected.txt (modified) (1 diff)
-
LayoutTests/http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-expected.txt (added)
-
LayoutTests/http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html (added)
-
LayoutTests/http/tests/storageAccess/resources/get-cookies.php (modified) (1 diff)
-
LayoutTests/http/tests/storageAccess/resources/produce-user-gesture-set-cookie-and-report-back.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/loader/ResourceLoadObserver.cpp (modified) (12 diffs)
-
Source/WebCore/loader/ResourceLoadObserver.h (modified) (4 diffs)
-
Source/WebCore/testing/Internals.cpp (modified) (1 diff)
-
Source/WebKit/CMakeLists.txt (modified) (1 diff)
-
Source/WebKit/ChangeLog (modified) (1 diff)
-
Source/WebKit/DerivedSources.make (modified) (1 diff)
-
Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp (modified) (2 diffs)
-
Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h (modified) (4 diffs)
-
Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp (modified) (3 diffs)
-
Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.h (modified) (1 diff)
-
Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.messages.in (modified) (1 diff)
-
Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.messages.in (deleted)
-
Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp (modified) (1 diff)
-
Source/WebKit/WebKit.xcodeproj/project.pbxproj (modified) (7 diffs)
-
Source/WebKit/WebProcess/InjectedBundle/API/c/WKBundle.cpp (modified) (1 diff)
-
Source/WebKit/WebProcess/WebProcess.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tags/Safari-608.1.13.4/LayoutTests/ChangeLog
r243383 r243723 1 2019-04-01 Alan Coon <alancoon@apple.com> 2 3 Cherry-pick r243671. rdar://problem/47859936 4 5 Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process 6 https://bugs.webkit.org/show_bug.cgi?id=196407 7 <rdar://problem/47859936> 8 9 Reviewed by Brent Fulgham. 10 11 Source/WebCore: 12 13 Test: http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html 14 15 This patch removes old code for the batching into "statistics updated" calls. 16 Since the move of Resource Load Statistics to the network process, all such 17 collection is done directly through dedicated calls to the network process. 18 19 The remaining functionality was renamed to make it more clear, i.e. 20 ResourceLoadObserver::notifyObserver() renamed to 21 ResourceLoadObserver::updateCentralStatisticsStore(). 22 23 * loader/ResourceLoadObserver.cpp: 24 (WebCore::ResourceLoadObserver::setStatisticsUpdatedCallback): 25 (WebCore::ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback): 26 (WebCore::ResourceLoadObserver::logSubresourceLoading): 27 (WebCore::ResourceLoadObserver::logWebSocketLoading): 28 (WebCore::ResourceLoadObserver::logUserInteractionWithReducedTimeResolution): 29 (WebCore::ResourceLoadObserver::requestStorageAccessUnderOpener): 30 (WebCore::ResourceLoadObserver::updateCentralStatisticsStore): 31 (WebCore::ResourceLoadObserver::clearState): 32 (WebCore::ResourceLoadObserver::setNotificationCallback): Deleted. 33 (WebCore::ResourceLoadObserver::ResourceLoadObserver): Deleted. 34 (WebCore::ResourceLoadObserver::scheduleNotificationIfNeeded): Deleted. 35 (WebCore::ResourceLoadObserver::notifyObserver): Deleted. 36 * loader/ResourceLoadObserver.h: 37 * testing/Internals.cpp: 38 (WebCore::Internals::notifyResourceLoadObserver): 39 40 Source/WebKit: 41 42 The two WebResourceLoadStatisticsStore IPC endpoints were left behind when we 43 moved Resource Load Statistics from the UI process to the network process. One 44 of the endpoints is the message RequestStorageAccessUnderOpener which underpins 45 our compatibility fix for federated logins using popups. This patch redirects 46 these IPC calls to the network process and cleans up some assumptions around 47 them. 48 49 * CMakeLists.txt: 50 Removed the old IPC receiver. 51 * DerivedSources.make: 52 Removed the old IPC receiver. 53 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp: 54 (WebKit::WebResourceLoadStatisticsStore::requestUpdate): Deleted. 55 This is no longer needed since there is a dedicated update mechanism 56 that actually sends the update. 57 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h: 58 * NetworkProcess/NetworkConnectionToWebProcess.cpp: 59 (WebKit::NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated): 60 (WebKit::NetworkConnectionToWebProcess::requestStorageAccessUnderOpener): 61 Two new IPC receivers to pipe the calls to the network process. 62 (WebKit::NetworkConnectionToWebProcess::requestResourceLoadStatisticsUpdate): Deleted. 63 NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated now serves 64 this purpose. 65 * NetworkProcess/NetworkConnectionToWebProcess.h: 66 * NetworkProcess/NetworkConnectionToWebProcess.messages.in: 67 * UIProcess/WebResourceLoadStatisticsStore.messages.in: Removed. 68 Removed the old IPC receiver. 69 * UIProcess/WebsiteData/WebsiteDataStore.cpp: 70 * WebKit.xcodeproj/project.pbxproj: 71 * WebProcess/InjectedBundle/API/c/WKBundle.cpp: 72 (WKBundleResourceLoadStatisticsNotifyObserver): 73 Function name update. 74 * WebProcess/WebProcess.cpp: 75 Now calls IPC to the network process instead of the UI process. 76 77 LayoutTests: 78 79 * http/tests/storageAccess/deny-storage-access-under-opener-expected.txt: 80 * http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-expected.txt: 81 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-expected.txt: Added. 82 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html: Added. 83 * http/tests/storageAccess/resources/get-cookies.php: 84 * http/tests/storageAccess/resources/produce-user-gesture-set-cookie-and-report-back.html: Added. 85 86 87 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@243671 268f45cc-cd09-0410-ab3c-d52691b4dbfc 88 89 2019-03-29 John Wilander <wilander@apple.com> 90 91 Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process 92 https://bugs.webkit.org/show_bug.cgi?id=196407 93 <rdar://problem/47859936> 94 95 Reviewed by Brent Fulgham. 96 97 * http/tests/storageAccess/deny-storage-access-under-opener-expected.txt: 98 * http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-expected.txt: 99 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-expected.txt: Added. 100 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html: Added. 101 * http/tests/storageAccess/resources/get-cookies.php: 102 * http/tests/storageAccess/resources/produce-user-gesture-set-cookie-and-report-back.html: Added. 103 1 104 2019-03-22 Ryan Haddad <ryanhaddad@apple.com> 2 105 -
tags/Safari-608.1.13.4/LayoutTests/http/tests/storageAccess/deny-storage-access-under-opener-expected.txt
r231450 r243723 15 15 Should not receive first-party cookie. 16 16 Did not receive cookie named 'firstPartyCookie'. 17 Did not receive cookie named ''.18 17 Client-side document.cookie: -
tags/Safari-608.1.13.4/LayoutTests/http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-expected.txt
r236563 r243723 15 15 Should not receive first-party cookie. 16 16 Did not receive cookie named 'firstPartyCookie'. 17 Did not receive cookie named ''.18 17 Client-side document.cookie: -
tags/Safari-608.1.13.4/LayoutTests/http/tests/storageAccess/resources/get-cookies.php
r235569 r243723 6 6 echo "Received cookie named '" . $_GET["name1"] . "'.<br>"; 7 7 } 8 if(!isset($_COOKIE[$_GET["name2"]])) { 9 echo "Did not receive cookie named '" . $_GET["name2"] . "'.<br>"; 10 } else { 11 echo "Received cookie named '" . $_GET["name2"] . "'.<br>"; 8 if(!empty($_GET["name2"])) { 9 if(!isset($_COOKIE[$_GET["name2"]])) { 10 echo "Did not receive cookie named '" . $_GET["name2"] . "'.<br>"; 11 } else { 12 echo "Received cookie named '" . $_GET["name2"] . "'.<br>"; 13 } 12 14 } 13 15 if(!empty($_GET["name3"])) { -
tags/Safari-608.1.13.4/Source/WebCore/ChangeLog
r243383 r243723 1 2019-04-01 Alan Coon <alancoon@apple.com> 2 3 Cherry-pick r243671. rdar://problem/47859936 4 5 Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process 6 https://bugs.webkit.org/show_bug.cgi?id=196407 7 <rdar://problem/47859936> 8 9 Reviewed by Brent Fulgham. 10 11 Source/WebCore: 12 13 Test: http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html 14 15 This patch removes old code for the batching into "statistics updated" calls. 16 Since the move of Resource Load Statistics to the network process, all such 17 collection is done directly through dedicated calls to the network process. 18 19 The remaining functionality was renamed to make it more clear, i.e. 20 ResourceLoadObserver::notifyObserver() renamed to 21 ResourceLoadObserver::updateCentralStatisticsStore(). 22 23 * loader/ResourceLoadObserver.cpp: 24 (WebCore::ResourceLoadObserver::setStatisticsUpdatedCallback): 25 (WebCore::ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback): 26 (WebCore::ResourceLoadObserver::logSubresourceLoading): 27 (WebCore::ResourceLoadObserver::logWebSocketLoading): 28 (WebCore::ResourceLoadObserver::logUserInteractionWithReducedTimeResolution): 29 (WebCore::ResourceLoadObserver::requestStorageAccessUnderOpener): 30 (WebCore::ResourceLoadObserver::updateCentralStatisticsStore): 31 (WebCore::ResourceLoadObserver::clearState): 32 (WebCore::ResourceLoadObserver::setNotificationCallback): Deleted. 33 (WebCore::ResourceLoadObserver::ResourceLoadObserver): Deleted. 34 (WebCore::ResourceLoadObserver::scheduleNotificationIfNeeded): Deleted. 35 (WebCore::ResourceLoadObserver::notifyObserver): Deleted. 36 * loader/ResourceLoadObserver.h: 37 * testing/Internals.cpp: 38 (WebCore::Internals::notifyResourceLoadObserver): 39 40 Source/WebKit: 41 42 The two WebResourceLoadStatisticsStore IPC endpoints were left behind when we 43 moved Resource Load Statistics from the UI process to the network process. One 44 of the endpoints is the message RequestStorageAccessUnderOpener which underpins 45 our compatibility fix for federated logins using popups. This patch redirects 46 these IPC calls to the network process and cleans up some assumptions around 47 them. 48 49 * CMakeLists.txt: 50 Removed the old IPC receiver. 51 * DerivedSources.make: 52 Removed the old IPC receiver. 53 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp: 54 (WebKit::WebResourceLoadStatisticsStore::requestUpdate): Deleted. 55 This is no longer needed since there is a dedicated update mechanism 56 that actually sends the update. 57 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h: 58 * NetworkProcess/NetworkConnectionToWebProcess.cpp: 59 (WebKit::NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated): 60 (WebKit::NetworkConnectionToWebProcess::requestStorageAccessUnderOpener): 61 Two new IPC receivers to pipe the calls to the network process. 62 (WebKit::NetworkConnectionToWebProcess::requestResourceLoadStatisticsUpdate): Deleted. 63 NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated now serves 64 this purpose. 65 * NetworkProcess/NetworkConnectionToWebProcess.h: 66 * NetworkProcess/NetworkConnectionToWebProcess.messages.in: 67 * UIProcess/WebResourceLoadStatisticsStore.messages.in: Removed. 68 Removed the old IPC receiver. 69 * UIProcess/WebsiteData/WebsiteDataStore.cpp: 70 * WebKit.xcodeproj/project.pbxproj: 71 * WebProcess/InjectedBundle/API/c/WKBundle.cpp: 72 (WKBundleResourceLoadStatisticsNotifyObserver): 73 Function name update. 74 * WebProcess/WebProcess.cpp: 75 Now calls IPC to the network process instead of the UI process. 76 77 LayoutTests: 78 79 * http/tests/storageAccess/deny-storage-access-under-opener-expected.txt: 80 * http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-expected.txt: 81 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-expected.txt: Added. 82 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html: Added. 83 * http/tests/storageAccess/resources/get-cookies.php: 84 * http/tests/storageAccess/resources/produce-user-gesture-set-cookie-and-report-back.html: Added. 85 86 87 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@243671 268f45cc-cd09-0410-ab3c-d52691b4dbfc 88 89 2019-03-29 John Wilander <wilander@apple.com> 90 91 Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process 92 https://bugs.webkit.org/show_bug.cgi?id=196407 93 <rdar://problem/47859936> 94 95 Reviewed by Brent Fulgham. 96 97 Test: http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html 98 99 This patch removes old code for the batching into "statistics updated" calls. 100 Since the move of Resource Load Statistics to the network process, all such 101 collection is done directly through dedicated calls to the network process. 102 103 The remaining functionality was renamed to make it more clear, i.e. 104 ResourceLoadObserver::notifyObserver() renamed to 105 ResourceLoadObserver::updateCentralStatisticsStore(). 106 107 * loader/ResourceLoadObserver.cpp: 108 (WebCore::ResourceLoadObserver::setStatisticsUpdatedCallback): 109 (WebCore::ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback): 110 (WebCore::ResourceLoadObserver::logSubresourceLoading): 111 (WebCore::ResourceLoadObserver::logWebSocketLoading): 112 (WebCore::ResourceLoadObserver::logUserInteractionWithReducedTimeResolution): 113 (WebCore::ResourceLoadObserver::requestStorageAccessUnderOpener): 114 (WebCore::ResourceLoadObserver::updateCentralStatisticsStore): 115 (WebCore::ResourceLoadObserver::clearState): 116 (WebCore::ResourceLoadObserver::setNotificationCallback): Deleted. 117 (WebCore::ResourceLoadObserver::ResourceLoadObserver): Deleted. 118 (WebCore::ResourceLoadObserver::scheduleNotificationIfNeeded): Deleted. 119 (WebCore::ResourceLoadObserver::notifyObserver): Deleted. 120 * loader/ResourceLoadObserver.h: 121 * testing/Internals.cpp: 122 (WebCore::Internals::notifyResourceLoadObserver): 123 1 124 2019-03-22 Ryan Haddad <ryanhaddad@apple.com> 2 125 -
tags/Safari-608.1.13.4/Source/WebCore/loader/ResourceLoadObserver.cpp
r242155 r243723 54 54 } 55 55 56 void ResourceLoadObserver::set NotificationCallback(WTF::Function<void(Vector<ResourceLoadStatistics>&&)>&& notificationCallback)56 void ResourceLoadObserver::setStatisticsUpdatedCallback(WTF::Function<void(Vector<ResourceLoadStatistics>&&)>&& notificationCallback) 57 57 { 58 58 ASSERT(!m_notificationCallback); … … 60 60 } 61 61 62 void ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback(WTF::Function<void( const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, const RegistrableDomain& openerDomain)>&& callback)62 void ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback(WTF::Function<void(PAL::SessionID sessionID, const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, const RegistrableDomain& openerDomain)>&& callback) 63 63 { 64 64 ASSERT(!m_requestStorageAccessUnderOpenerCallback); … … 90 90 } 91 91 92 ResourceLoadObserver::ResourceLoadObserver()93 : m_notificationTimer(*this, &ResourceLoadObserver::notifyObserver)94 {95 }96 97 92 static inline bool is3xxRedirect(const ResourceResponse& response) 98 93 { … … 134 129 return; 135 130 136 bool shouldCallNotificationCallback = false;137 131 { 138 132 auto& targetStatistics = ensureResourceStatisticsForRegistrableDomain(targetDomain); 139 133 auto lastSeen = ResourceLoadStatistics::reduceTimeResolution(WallTime::now()); 140 134 targetStatistics.lastSeen = lastSeen; 141 if (targetStatistics.subresourceUnderTopFrameDomains.add(topFrameDomain).isNewEntry) 142 shouldCallNotificationCallback = true; 135 targetStatistics.subresourceUnderTopFrameDomains.add(topFrameDomain); 143 136 144 137 m_logSubresourceLoadingNotificationCallback(page->sessionID(), targetDomain, topFrameDomain, lastSeen); … … 147 140 if (isRedirect) { 148 141 auto& redirectingOriginStatistics = ensureResourceStatisticsForRegistrableDomain(redirectedFromDomain); 149 bool isNewRedirectToEntry = redirectingOriginStatistics.subresourceUniqueRedirectsTo.add(targetDomain).isNewEntry;142 redirectingOriginStatistics.subresourceUniqueRedirectsTo.add(targetDomain); 150 143 auto& targetStatistics = ensureResourceStatisticsForRegistrableDomain(targetDomain); 151 bool isNewRedirectFromEntry = targetStatistics.subresourceUniqueRedirectsFrom.add(redirectedFromDomain).isNewEntry; 152 153 if (isNewRedirectToEntry || isNewRedirectFromEntry) 154 shouldCallNotificationCallback = true; 144 targetStatistics.subresourceUniqueRedirectsFrom.add(redirectedFromDomain); 155 145 156 146 m_logSubresourceRedirectNotificationCallback(page->sessionID(), redirectedFromDomain, targetDomain); 157 147 } 158 159 if (shouldCallNotificationCallback)160 scheduleNotificationIfNeeded();161 148 } 162 149 … … 182 169 auto& targetStatistics = ensureResourceStatisticsForRegistrableDomain(targetDomain); 183 170 targetStatistics.lastSeen = lastSeen; 184 if (targetStatistics.subresourceUnderTopFrameDomains.add(topFrameDomain).isNewEntry) 185 scheduleNotificationIfNeeded(); 171 targetStatistics.subresourceUnderTopFrameDomains.add(topFrameDomain); 186 172 187 173 m_logWebSocketLoadingNotificationCallback(sessionID, targetDomain, topFrameDomain, lastSeen); … … 216 202 if (auto* openerFrame = openerDocument->frame()) { 217 203 if (auto openerPageID = openerFrame->loader().client().pageID()) 218 requestStorageAccessUnderOpener( topFrameDomain, openerPageID.value(), *openerDocument);204 requestStorageAccessUnderOpener(document.sessionID(), topFrameDomain, openerPageID.value(), *openerDocument); 219 205 } 220 206 } … … 224 210 m_logUserInteractionNotificationCallback(document.sessionID(), topFrameDomain); 225 211 #endif 226 227 m_notificationTimer.stop();228 notifyObserver();229 212 230 213 #if ENABLE(RESOURCE_LOAD_STATISTICS) && !RELEASE_LOG_DISABLED … … 251 234 252 235 #if ENABLE(RESOURCE_LOAD_STATISTICS) 253 void ResourceLoadObserver::requestStorageAccessUnderOpener( const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, Document& openerDocument)236 void ResourceLoadObserver::requestStorageAccessUnderOpener(PAL::SessionID sessionID, const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, Document& openerDocument) 254 237 { 255 238 auto openerUrl = openerDocument.url(); … … 258 241 && !openerDocument.hasRequestedPageSpecificStorageAccessWithUserInteraction(domainInNeedOfStorageAccess) 259 242 && !equalIgnoringASCIICase(openerUrl.string(), WTF::blankURL())) { 260 m_requestStorageAccessUnderOpenerCallback( domainInNeedOfStorageAccess, openerPageID, openerDomain);243 m_requestStorageAccessUnderOpenerCallback(sessionID, domainInNeedOfStorageAccess, openerPageID, openerDomain); 261 244 // Remember user interaction-based requests since they don't need to be repeated. 262 245 openerDocument.setHasRequestedPageSpecificStorageAccessWithUserInteraction(domainInNeedOfStorageAccess); … … 383 366 } 384 367 385 void ResourceLoadObserver::scheduleNotificationIfNeeded() 386 { 387 ASSERT(m_notificationCallback); 388 if (m_resourceStatisticsMap.isEmpty()) { 389 m_notificationTimer.stop(); 390 return; 391 } 392 393 if (!m_notificationTimer.isActive()) 394 m_notificationTimer.startOneShot(minimumNotificationInterval); 395 } 396 397 void ResourceLoadObserver::notifyObserver() 398 { 399 ASSERT(m_notificationCallback); 400 m_notificationTimer.stop(); 368 void ResourceLoadObserver::updateCentralStatisticsStore() 369 { 401 370 m_notificationCallback(takeStatistics()); 402 371 } … … 425 394 void ResourceLoadObserver::clearState() 426 395 { 427 m_notificationTimer.stop();428 396 m_resourceStatisticsMap.clear(); 429 397 m_lastReportedUserInteractionMap.clear(); -
tags/Safari-608.1.13.4/Source/WebCore/loader/ResourceLoadObserver.h
r242155 r243723 73 73 WEBCORE_EXPORT String statisticsForURL(const URL&); 74 74 75 WEBCORE_EXPORT void set NotificationCallback(WTF::Function<void(Vector<ResourceLoadStatistics>&&)>&&);76 WEBCORE_EXPORT void setRequestStorageAccessUnderOpenerCallback(Function<void( const RegistrableDomain&, uint64_t, const RegistrableDomain&)>&&);75 WEBCORE_EXPORT void setStatisticsUpdatedCallback(WTF::Function<void(Vector<ResourceLoadStatistics>&&)>&&); 76 WEBCORE_EXPORT void setRequestStorageAccessUnderOpenerCallback(Function<void(PAL::SessionID, const RegistrableDomain&, uint64_t, const RegistrableDomain&)>&&); 77 77 WEBCORE_EXPORT void setLogUserInteractionNotificationCallback(Function<void(PAL::SessionID, const RegistrableDomain&)>&&); 78 78 WEBCORE_EXPORT void setLogWebSocketLoadingNotificationCallback(Function<void(PAL::SessionID, const RegistrableDomain&, const RegistrableDomain&, WallTime)>&&); … … 80 80 WEBCORE_EXPORT void setLogSubresourceRedirectNotificationCallback(Function<void(PAL::SessionID, const RegistrableDomain&, const RegistrableDomain&)>&&); 81 81 82 WEBCORE_EXPORT void notifyObserver();82 WEBCORE_EXPORT void updateCentralStatisticsStore(); 83 83 WEBCORE_EXPORT void clearState(); 84 84 … … 89 89 90 90 private: 91 ResourceLoadObserver();92 93 91 bool shouldLog(bool usesEphemeralSession) const; 94 92 ResourceLoadStatistics& ensureResourceStatisticsForRegistrableDomain(const RegistrableDomain&); 95 93 96 void scheduleNotificationIfNeeded();97 94 Vector<ResourceLoadStatistics> takeStatistics(); 98 95 99 96 #if ENABLE(RESOURCE_LOAD_STATISTICS) 100 void requestStorageAccessUnderOpener( const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, Document& openerDocument);97 void requestStorageAccessUnderOpener(PAL::SessionID, const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, Document& openerDocument); 101 98 #endif 102 99 … … 104 101 HashMap<RegistrableDomain, WTF::WallTime> m_lastReportedUserInteractionMap; 105 102 Function<void(Vector<ResourceLoadStatistics>&&)> m_notificationCallback; 106 Function<void( const RegistrableDomain&, uint64_t, const RegistrableDomain&)> m_requestStorageAccessUnderOpenerCallback;103 Function<void(PAL::SessionID, const RegistrableDomain&, uint64_t, const RegistrableDomain&)> m_requestStorageAccessUnderOpenerCallback; 107 104 Function<void(PAL::SessionID, const RegistrableDomain&)> m_logUserInteractionNotificationCallback; 108 105 Function<void(PAL::SessionID, const RegistrableDomain&, const RegistrableDomain&, WallTime)> m_logWebSocketLoadingNotificationCallback; 109 106 Function<void(PAL::SessionID, const RegistrableDomain&, const RegistrableDomain&, WallTime)> m_logSubresourceLoadingNotificationCallback; 110 107 Function<void(PAL::SessionID, const RegistrableDomain&, const RegistrableDomain&)> m_logSubresourceRedirectNotificationCallback; 111 112 Timer m_notificationTimer;113 108 #if ENABLE(RESOURCE_LOAD_STATISTICS) && !RELEASE_LOG_DISABLED 114 109 uint64_t m_loggingCounter { 0 }; -
tags/Safari-608.1.13.4/Source/WebCore/testing/Internals.cpp
r243324 r243723 4919 4919 void Internals::notifyResourceLoadObserver() 4920 4920 { 4921 ResourceLoadObserver::shared(). notifyObserver();4921 ResourceLoadObserver::shared().updateCentralStatisticsStore(); 4922 4922 } 4923 4923 -
tags/Safari-608.1.13.4/Source/WebKit/CMakeLists.txt
r242503 r243723 145 145 UIProcess/WebProcessPool.messages.in 146 146 UIProcess/WebProcessProxy.messages.in 147 UIProcess/WebResourceLoadStatisticsStore.messages.in148 147 149 148 UIProcess/Automation/WebAutomationSession.messages.in -
tags/Safari-608.1.13.4/Source/WebKit/ChangeLog
r243651 r243723 1 2019-04-01 Alan Coon <alancoon@apple.com> 2 3 Cherry-pick r243671. rdar://problem/47859936 4 5 Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process 6 https://bugs.webkit.org/show_bug.cgi?id=196407 7 <rdar://problem/47859936> 8 9 Reviewed by Brent Fulgham. 10 11 Source/WebCore: 12 13 Test: http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html 14 15 This patch removes old code for the batching into "statistics updated" calls. 16 Since the move of Resource Load Statistics to the network process, all such 17 collection is done directly through dedicated calls to the network process. 18 19 The remaining functionality was renamed to make it more clear, i.e. 20 ResourceLoadObserver::notifyObserver() renamed to 21 ResourceLoadObserver::updateCentralStatisticsStore(). 22 23 * loader/ResourceLoadObserver.cpp: 24 (WebCore::ResourceLoadObserver::setStatisticsUpdatedCallback): 25 (WebCore::ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback): 26 (WebCore::ResourceLoadObserver::logSubresourceLoading): 27 (WebCore::ResourceLoadObserver::logWebSocketLoading): 28 (WebCore::ResourceLoadObserver::logUserInteractionWithReducedTimeResolution): 29 (WebCore::ResourceLoadObserver::requestStorageAccessUnderOpener): 30 (WebCore::ResourceLoadObserver::updateCentralStatisticsStore): 31 (WebCore::ResourceLoadObserver::clearState): 32 (WebCore::ResourceLoadObserver::setNotificationCallback): Deleted. 33 (WebCore::ResourceLoadObserver::ResourceLoadObserver): Deleted. 34 (WebCore::ResourceLoadObserver::scheduleNotificationIfNeeded): Deleted. 35 (WebCore::ResourceLoadObserver::notifyObserver): Deleted. 36 * loader/ResourceLoadObserver.h: 37 * testing/Internals.cpp: 38 (WebCore::Internals::notifyResourceLoadObserver): 39 40 Source/WebKit: 41 42 The two WebResourceLoadStatisticsStore IPC endpoints were left behind when we 43 moved Resource Load Statistics from the UI process to the network process. One 44 of the endpoints is the message RequestStorageAccessUnderOpener which underpins 45 our compatibility fix for federated logins using popups. This patch redirects 46 these IPC calls to the network process and cleans up some assumptions around 47 them. 48 49 * CMakeLists.txt: 50 Removed the old IPC receiver. 51 * DerivedSources.make: 52 Removed the old IPC receiver. 53 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp: 54 (WebKit::WebResourceLoadStatisticsStore::requestUpdate): Deleted. 55 This is no longer needed since there is a dedicated update mechanism 56 that actually sends the update. 57 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h: 58 * NetworkProcess/NetworkConnectionToWebProcess.cpp: 59 (WebKit::NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated): 60 (WebKit::NetworkConnectionToWebProcess::requestStorageAccessUnderOpener): 61 Two new IPC receivers to pipe the calls to the network process. 62 (WebKit::NetworkConnectionToWebProcess::requestResourceLoadStatisticsUpdate): Deleted. 63 NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated now serves 64 this purpose. 65 * NetworkProcess/NetworkConnectionToWebProcess.h: 66 * NetworkProcess/NetworkConnectionToWebProcess.messages.in: 67 * UIProcess/WebResourceLoadStatisticsStore.messages.in: Removed. 68 Removed the old IPC receiver. 69 * UIProcess/WebsiteData/WebsiteDataStore.cpp: 70 * WebKit.xcodeproj/project.pbxproj: 71 * WebProcess/InjectedBundle/API/c/WKBundle.cpp: 72 (WKBundleResourceLoadStatisticsNotifyObserver): 73 Function name update. 74 * WebProcess/WebProcess.cpp: 75 Now calls IPC to the network process instead of the UI process. 76 77 LayoutTests: 78 79 * http/tests/storageAccess/deny-storage-access-under-opener-expected.txt: 80 * http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-expected.txt: 81 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-expected.txt: Added. 82 * http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html: Added. 83 * http/tests/storageAccess/resources/get-cookies.php: 84 * http/tests/storageAccess/resources/produce-user-gesture-set-cookie-and-report-back.html: Added. 85 86 87 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@243671 268f45cc-cd09-0410-ab3c-d52691b4dbfc 88 89 2019-03-29 John Wilander <wilander@apple.com> 90 91 Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process 92 https://bugs.webkit.org/show_bug.cgi?id=196407 93 <rdar://problem/47859936> 94 95 Reviewed by Brent Fulgham. 96 97 The two WebResourceLoadStatisticsStore IPC endpoints were left behind when we 98 moved Resource Load Statistics from the UI process to the network process. One 99 of the endpoints is the message RequestStorageAccessUnderOpener which underpins 100 our compatibility fix for federated logins using popups. This patch redirects 101 these IPC calls to the network process and cleans up some assumptions around 102 them. 103 104 * CMakeLists.txt: 105 Removed the old IPC receiver. 106 * DerivedSources.make: 107 Removed the old IPC receiver. 108 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp: 109 (WebKit::WebResourceLoadStatisticsStore::requestUpdate): Deleted. 110 This is no longer needed since there is a dedicated update mechanism 111 that actually sends the update. 112 * NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h: 113 * NetworkProcess/NetworkConnectionToWebProcess.cpp: 114 (WebKit::NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated): 115 (WebKit::NetworkConnectionToWebProcess::requestStorageAccessUnderOpener): 116 Two new IPC receivers to pipe the calls to the network process. 117 (WebKit::NetworkConnectionToWebProcess::requestResourceLoadStatisticsUpdate): Deleted. 118 NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated now serves 119 this purpose. 120 * NetworkProcess/NetworkConnectionToWebProcess.h: 121 * NetworkProcess/NetworkConnectionToWebProcess.messages.in: 122 * UIProcess/WebResourceLoadStatisticsStore.messages.in: Removed. 123 Removed the old IPC receiver. 124 * UIProcess/WebsiteData/WebsiteDataStore.cpp: 125 * WebKit.xcodeproj/project.pbxproj: 126 * WebProcess/InjectedBundle/API/c/WKBundle.cpp: 127 (WKBundleResourceLoadStatisticsNotifyObserver): 128 Function name update. 129 * WebProcess/WebProcess.cpp: 130 Now calls IPC to the network process instead of the UI process. 131 1 132 2019-03-29 Babak Shafiei <bshafiei@apple.com> 2 133 -
tags/Safari-608.1.13.4/Source/WebKit/DerivedSources.make
r243195 r243723 179 179 WebRTCResolver \ 180 180 WebRTCSocket \ 181 WebResourceLoadStatisticsStore \182 181 WebResourceLoader \ 183 182 WebSWClientConnection \ -
tags/Safari-608.1.13.4/Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp
r243181 r243723 43 43 #include "WebProcessPool.h" 44 44 #include "WebProcessProxy.h" 45 #include "WebResourceLoadStatisticsStoreMessages.h"46 45 #include "WebResourceLoadStatisticsTelemetry.h" 47 46 #include "WebsiteDataFetchOption.h" … … 252 251 } 253 252 254 void WebResourceLoadStatisticsStore::requestUpdate()255 {256 resourceLoadStatisticsUpdated({ });257 }258 259 253 void WebResourceLoadStatisticsStore::resourceLoadStatisticsUpdated(Vector<WebCore::ResourceLoadStatistics>&& origins) 260 254 { -
tags/Safari-608.1.13.4/Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h
r243181 r243723 67 67 }; 68 68 69 class WebResourceLoadStatisticsStore final : public ThreadSafeRefCounted<WebResourceLoadStatisticsStore, WTF::DestructionThread::Main> , public IPC::MessageReceiver{69 class WebResourceLoadStatisticsStore final : public ThreadSafeRefCounted<WebResourceLoadStatisticsStore, WTF::DestructionThread::Main> { 70 70 public: 71 71 using ResourceLoadStatistics = WebCore::ResourceLoadStatistics; … … 121 121 void requestStorageAccess(const SubFrameDomain&, const TopFrameDomain&, Optional<FrameID>, PageID, CompletionHandler<void(StorageAccessStatus)>&&); 122 122 void requestStorageAccessGranted(const SubFrameDomain&, const TopFrameDomain&, FrameID, PageID, CompletionHandler<void(bool)>&&); 123 void requestUpdate();124 123 void setLastSeen(const RegistrableDomain&, Seconds, CompletionHandler<void()>&&); 125 124 void setPrevalentResource(const RegistrableDomain&, CompletionHandler<void()>&&); … … 179 178 void notifyPageStatisticsTelemetryFinished(unsigned totalPrevalentResources, unsigned totalPrevalentResourcesWithUserInteraction, unsigned top3SubframeUnderTopFrameOrigins) const; 180 179 180 void resourceLoadStatisticsUpdated(Vector<ResourceLoadStatistics>&&); 181 void requestStorageAccessUnderOpener(DomainInNeedOfStorageAccess&&, uint64_t openerPageID, OpenerDomain&&); 182 181 183 private: 182 184 explicit WebResourceLoadStatisticsStore(NetworkSession&, const String&, ShouldIncludeLocalhost); … … 184 186 void postTask(WTF::Function<void()>&&); 185 187 static void postTaskReply(WTF::Function<void()>&&); 186 187 // IPC::MessageReceiver.188 void didReceiveMessage(IPC::Connection&, IPC::Decoder&) override;189 190 // IPC message handlers.191 void resourceLoadStatisticsUpdated(Vector<ResourceLoadStatistics>&& origins);192 void requestStorageAccessUnderOpener(DomainInNeedOfStorageAccess&&, uint64_t openerPageID, OpenerDomain&&);193 188 194 189 void performDailyTasks(); -
tags/Safari-608.1.13.4/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp
r243258 r243723 654 654 } 655 655 656 void NetworkConnectionToWebProcess::re questResourceLoadStatisticsUpdate()656 void NetworkConnectionToWebProcess::resourceLoadStatisticsUpdated(Vector<WebCore::ResourceLoadStatistics>&& statistics) 657 657 { 658 658 for (auto& networkSession : networkProcess().networkSessions().values()) { … … 661 661 662 662 if (auto* resourceLoadStatistics = networkSession->resourceLoadStatistics()) 663 resourceLoadStatistics->re questUpdate();663 resourceLoadStatistics->resourceLoadStatisticsUpdated(WTFMove(statistics)); 664 664 } 665 665 } … … 673 673 { 674 674 networkProcess().requestStorageAccessGranted(sessionID, subFrameDomain, topFrameDomain, frameID, pageID, WTFMove(completionHandler)); 675 } 676 677 void NetworkConnectionToWebProcess::requestStorageAccessUnderOpener(PAL::SessionID sessionID, WebCore::RegistrableDomain&& domainInNeedOfStorageAccess, uint64_t openerPageID, WebCore::RegistrableDomain&& openerDomain) 678 { 679 if (auto networkSession = networkProcess().networkSession(sessionID)) { 680 if (auto* resourceLoadStatistics = networkSession->resourceLoadStatistics()) 681 resourceLoadStatistics->requestStorageAccessUnderOpener(WTFMove(domainInNeedOfStorageAccess), openerPageID, WTFMove(openerDomain)); 682 } 675 683 } 676 684 #endif -
tags/Safari-608.1.13.4/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.h
r243258 r243723 219 219 void logSubresourceLoading(PAL::SessionID, const RegistrableDomain& targetDomain, const RegistrableDomain& topFrameDomain, WallTime lastSeen); 220 220 void logSubresourceRedirect(PAL::SessionID, const RegistrableDomain& sourceDomain, const RegistrableDomain& targetDomain); 221 void re questResourceLoadStatisticsUpdate();221 void resourceLoadStatisticsUpdated(Vector<WebCore::ResourceLoadStatistics>&&); 222 222 void hasStorageAccess(PAL::SessionID, const RegistrableDomain& subFrameDomain, const RegistrableDomain& topFrameDomain, uint64_t frameID, uint64_t pageID, CompletionHandler<void(bool)>&&); 223 223 void requestStorageAccess(PAL::SessionID, const RegistrableDomain& subFrameDomain, const RegistrableDomain& topFrameDomain, uint64_t frameID, uint64_t pageID, CompletionHandler<void(bool)>&&); 224 void requestStorageAccessUnderOpener(PAL::SessionID, WebCore::RegistrableDomain&& domainInNeedOfStorageAccess, uint64_t openerPageID, WebCore::RegistrableDomain&& openerDomain); 224 225 #endif 225 226 -
tags/Safari-608.1.13.4/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.messages.in
r243345 r243723 63 63 LogSubresourceLoading(PAL::SessionID sessionID, WebCore::RegistrableDomain targetDomain, WebCore::RegistrableDomain topFrameDomain, WallTime lastSeen) 64 64 LogSubresourceRedirect(PAL::SessionID sessionID, WebCore::RegistrableDomain sourceDomain, WebCore::RegistrableDomain targetDomain) 65 Re questResourceLoadStatisticsUpdate();65 ResourceLoadStatisticsUpdated(Vector<WebCore::ResourceLoadStatistics> statistics) 66 66 HasStorageAccess(PAL::SessionID sessionID, WebCore::RegistrableDomain subFrameDomain, WebCore::RegistrableDomain topFrameDomain, uint64_t frameID, uint64_t pageID) -> (bool hasStorageAccess) Async 67 67 RequestStorageAccess(PAL::SessionID sessionID, WebCore::RegistrableDomain subFrameDomain, WebCore::RegistrableDomain topFrameDomain, uint64_t frameID, uint64_t pageID) -> (bool accessGranted) Async 68 RequestStorageAccessUnderOpener(PAL::SessionID sessionID, WebCore::RegistrableDomain domainInNeedOfStorageAccess, uint64_t openerPageID, WebCore::RegistrableDomain openerDomain) 68 69 #endif 69 70 -
tags/Safari-608.1.13.4/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
r243375 r243723 41 41 #include "WebProcessPool.h" 42 42 #include "WebResourceLoadStatisticsStore.h" 43 #include "WebResourceLoadStatisticsStoreMessages.h"44 43 #include "WebsiteData.h" 45 44 #include "WebsiteDataStoreClient.h" -
tags/Safari-608.1.13.4/Source/WebKit/WebKit.xcodeproj/project.pbxproj
r243384 r243723 1123 1123 7A78FF32224191960096483E /* WKStorageAccessAlert.h in Headers */ = {isa = PBXBuildFile; fileRef = 7A78FF2E224191750096483E /* WKStorageAccessAlert.h */; }; 1124 1124 7A78FF332241919B0096483E /* WKStorageAccessAlert.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7A78FF2F224191760096483E /* WKStorageAccessAlert.mm */; }; 1125 7A791EFA1C7CFCF100C4C52B /* WebResourceLoadStatisticsStoreMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7A791EF91C7CFB3700C4C52B /* WebResourceLoadStatisticsStoreMessageReceiver.cpp */; };1126 7A791EFB1C7CFD0100C4C52B /* WebResourceLoadStatisticsStoreMessages.h in Headers */ = {isa = PBXBuildFile; fileRef = 7A791EF81C7CFB1000C4C52B /* WebResourceLoadStatisticsStoreMessages.h */; };1127 1125 7A821F4C1E2F673900604577 /* LegacyCustomProtocolManagerClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 7A821F4B1E2F664800604577 /* LegacyCustomProtocolManagerClient.h */; }; 1128 1126 7A821F501E2F7A7500604577 /* APICustomProtocolManagerClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 7A821F4F1E2F7A5C00604577 /* APICustomProtocolManagerClient.h */; }; … … 3585 3583 7A78FF2E224191750096483E /* WKStorageAccessAlert.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKStorageAccessAlert.h; sourceTree = "<group>"; }; 3586 3584 7A78FF2F224191760096483E /* WKStorageAccessAlert.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WKStorageAccessAlert.mm; sourceTree = "<group>"; }; 3587 7A791EF81C7CFB1000C4C52B /* WebResourceLoadStatisticsStoreMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WebResourceLoadStatisticsStoreMessages.h; path = DerivedSources/WebKit2/WebResourceLoadStatisticsStoreMessages.h; sourceTree = BUILT_PRODUCTS_DIR; };3588 7A791EF91C7CFB3700C4C52B /* WebResourceLoadStatisticsStoreMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = WebResourceLoadStatisticsStoreMessageReceiver.cpp; path = DerivedSources/WebKit2/WebResourceLoadStatisticsStoreMessageReceiver.cpp; sourceTree = BUILT_PRODUCTS_DIR; };3589 3585 7A821F491E2F65DD00604577 /* LegacyCustomProtocolManagerProxy.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LegacyCustomProtocolManagerProxy.cpp; path = CustomProtocols/LegacyCustomProtocolManagerProxy.cpp; sourceTree = "<group>"; }; 3590 3586 7A821F4B1E2F664800604577 /* LegacyCustomProtocolManagerClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LegacyCustomProtocolManagerClient.h; sourceTree = "<group>"; }; … … 3595 3591 7A8A9D591EF13020009801AE /* APIInjectedBundleBundleClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APIInjectedBundleBundleClient.h; sourceTree = "<group>"; }; 3596 3592 7A8A9D5B1EF1458E009801AE /* APIInjectedBundlePageResourceLoadClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APIInjectedBundlePageResourceLoadClient.h; sourceTree = "<group>"; }; 3597 7A9CD8C21C779AD600D9F6C7 /* WebResourceLoadStatisticsStore.messages.in */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = WebResourceLoadStatisticsStore.messages.in; sourceTree = "<group>"; };3598 3593 7AB6EA441EEAAE2300037B2B /* APIIconDatabaseClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APIIconDatabaseClient.h; sourceTree = "<group>"; }; 3599 3594 7AB6EA461EEAB6B000037B2B /* APIGeolocationProvider.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APIGeolocationProvider.h; sourceTree = "<group>"; }; … … 7615 7610 BC032DCF10F4389F0058C15A /* WebProcessProxy.h */, 7616 7611 BCEE7AB312817095009827DA /* WebProcessProxy.messages.in */, 7617 7A9CD8C21C779AD600D9F6C7 /* WebResourceLoadStatisticsStore.messages.in */,7618 7612 51D124241E6D3CC3002B2820 /* WebURLSchemeHandler.cpp */, 7619 7613 51D124251E6D3CC3002B2820 /* WebURLSchemeHandler.h */, … … 8668 8662 51F060DD1654317500F3281B /* WebResourceLoaderMessageReceiver.cpp */, 8669 8663 51F060DE1654317500F3281B /* WebResourceLoaderMessages.h */, 8670 7A791EF91C7CFB3700C4C52B /* WebResourceLoadStatisticsStoreMessageReceiver.cpp */,8671 7A791EF81C7CFB1000C4C52B /* WebResourceLoadStatisticsStoreMessages.h */,8672 8664 51F060DD1654317500F3281F /* WebRTCMonitorMessageReceiver.cpp */, 8673 8665 51F060DD1654317500F3282C /* WebRTCResolverMessageReceiver.cpp */, … … 9688 9680 51F060E01654317F00F3281B /* WebResourceLoaderMessages.h in Headers */, 9689 9681 7AFBD36321E50F39005DBACB /* WebResourceLoadStatisticsStore.h in Headers */, 9690 7A791EFB1C7CFD0100C4C52B /* WebResourceLoadStatisticsStoreMessages.h in Headers */,9691 9682 413075B01DE85F580039EC69 /* WebRTCMonitor.h in Headers */, 9692 9683 41FAF5F51E3C0649001AE678 /* WebRTCResolver.h in Headers */, … … 11199 11190 BCEE7AD012817988009827DA /* WebProcessProxyMessageReceiver.cpp in Sources */, 11200 11191 51F060E11654318500F3281B /* WebResourceLoaderMessageReceiver.cpp in Sources */, 11201 7A791EFA1C7CFCF100C4C52B /* WebResourceLoadStatisticsStoreMessageReceiver.cpp in Sources */,11202 11192 51F060E11654318500F3281F /* WebRTCMonitorMessageReceiver.cpp in Sources */, 11203 11193 51F060E11654318500F3282C /* WebRTCResolverMessageReceiver.cpp in Sources */, -
tags/Safari-608.1.13.4/Source/WebKit/WebProcess/InjectedBundle/API/c/WKBundle.cpp
r242339 r243723 324 324 void WKBundleResourceLoadStatisticsNotifyObserver(WKBundleRef) 325 325 { 326 WebCore::ResourceLoadObserver::shared(). notifyObserver();326 WebCore::ResourceLoadObserver::shared().updateCentralStatisticsStore(); 327 327 } 328 328 -
tags/Safari-608.1.13.4/Source/WebKit/WebProcess/WebProcess.cpp
r243384 r243723 66 66 #include "WebProcessPoolMessages.h" 67 67 #include "WebProcessProxyMessages.h" 68 #include "WebResourceLoadStatisticsStoreMessages.h"69 68 #include "WebSWContextManagerConnection.h" 70 69 #include "WebSWContextManagerConnectionMessages.h" … … 216 215 217 216 #if ENABLE(RESOURCE_LOAD_STATISTICS) 218 ResourceLoadObserver::shared().setNotificationCallback([this] (Vector<ResourceLoadStatistics>&& statistics) { 219 parentProcessConnection()->send(Messages::WebResourceLoadStatisticsStore::ResourceLoadStatisticsUpdated(WTFMove(statistics)), 0); 220 221 ensureNetworkProcessConnection().connection().send(Messages::NetworkConnectionToWebProcess::RequestResourceLoadStatisticsUpdate(), 0); 217 ResourceLoadObserver::shared().setStatisticsUpdatedCallback([this] (Vector<ResourceLoadStatistics>&& statistics) { 218 ensureNetworkProcessConnection().connection().send(Messages::NetworkConnectionToWebProcess::ResourceLoadStatisticsUpdated(WTFMove(statistics)), 0); 222 219 }); 223 220 224 ResourceLoadObserver::shared().setRequestStorageAccessUnderOpenerCallback([this] ( const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, const RegistrableDomain& openerDomain) {225 parentProcessConnection()->send(Messages::WebResourceLoadStatisticsStore::RequestStorageAccessUnderOpener(domainInNeedOfStorageAccess, openerPageID, openerDomain), 0);221 ResourceLoadObserver::shared().setRequestStorageAccessUnderOpenerCallback([this] (PAL::SessionID sessionID, const RegistrableDomain& domainInNeedOfStorageAccess, uint64_t openerPageID, const RegistrableDomain& openerDomain) { 222 ensureNetworkProcessConnection().connection().send(Messages::NetworkConnectionToWebProcess::RequestStorageAccessUnderOpener(sessionID, domainInNeedOfStorageAccess, openerPageID, openerDomain), 0); 226 223 }); 227 224 #endif
Note:
See TracChangeset
for help on using the changeset viewer.