Diff
Modified: trunk/Source/WebCore/ChangeLog (250044 => 250045)
--- trunk/Source/WebCore/ChangeLog 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/ChangeLog 2019-09-18 18:37:13 UTC (rev 250045)
@@ -1,5 +1,53 @@
2019-09-18 Chris Dumez <[email protected]>
+ CacheStorageProvider::createCacheStorageConnection() does not need to take in a SessionID
+ https://bugs.webkit.org/show_bug.cgi?id=201920
+
+ Reviewed by Geoffrey Garen.
+
+ CacheStorageProvider::createCacheStorageConnection() does not need to take in a SessionID.
+ This sessionID is no longer used now that we have a session per WebProcess.
+
+ * Modules/cache/CacheStorageConnection.cpp:
+ (WebCore::formDataSize):
+ (WebCore::CacheStorageConnection::computeRealBodySize):
+ * Modules/cache/CacheStorageConnection.h:
+ * Modules/cache/DOMWindowCaches.cpp:
+ (WebCore::DOMWindowCaches::caches const):
+ * Modules/cache/WorkerCacheStorageConnection.cpp:
+ (WebCore::WorkerCacheStorageConnection::sessionID const): Deleted.
+ * Modules/cache/WorkerCacheStorageConnection.h:
+ * fileapi/Blob.cpp:
+ (WebCore::Blob::size const):
+ * fileapi/ThreadableBlobRegistry.cpp:
+ (WebCore::ThreadableBlobRegistry::blobSize):
+ * fileapi/ThreadableBlobRegistry.h:
+ * loader/cache/KeepaliveRequestTracker.cpp:
+ (WebCore::KeepaliveRequestTracker::tryRegisterRequest):
+ (WebCore::KeepaliveRequestTracker::registerRequest):
+ (WebCore::KeepaliveRequestTracker::unregisterRequest):
+ * page/CacheStorageProvider.h:
+ (WebCore::CacheStorageProvider::createCacheStorageConnection):
+ * platform/network/BlobRegistry.h:
+ * platform/network/FormData.cpp:
+ (WebCore::FormDataElement::lengthInBytes const):
+ (WebCore::FormData::lengthInBytes const):
+ * platform/network/FormData.h:
+ * testing/Internals.cpp:
+ (WebCore::Internals::clearCacheStorageMemoryRepresentation):
+ (WebCore::Internals::cacheStorageEngineRepresentation):
+ (WebCore::Internals::updateQuotaBasedOnSpaceUsage):
+ * workers/WorkerMessagingProxy.cpp:
+ (WebCore::WorkerMessagingProxy::createCacheStorageConnection):
+ * workers/service/context/ServiceWorkerThreadProxy.cpp:
+ (WebCore::ServiceWorkerThreadProxy::ServiceWorkerThreadProxy):
+ (WebCore::ServiceWorkerThreadProxy::createCacheStorageConnection):
+ * workers/service/context/ServiceWorkerThreadProxy.h:
+ * xml/XMLHttpRequest.cpp:
+ (WebCore::XMLHttpRequest::createRequest):
+
+2019-09-18 Chris Dumez <[email protected]>
+
Drop FrameLoaderClient::sessionID()
https://bugs.webkit.org/show_bug.cgi?id=201916
Modified: trunk/Source/WebCore/Modules/cache/CacheStorageConnection.cpp (250044 => 250045)
--- trunk/Source/WebCore/Modules/cache/CacheStorageConnection.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/Modules/cache/CacheStorageConnection.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -33,14 +33,14 @@
namespace WebCore {
using namespace WebCore::DOMCacheEngine;
-static inline uint64_t formDataSize(const FormData& formData, PAL::SessionID sessionID)
+static inline uint64_t formDataSize(const FormData& formData)
{
if (isMainThread())
- return formData.lengthInBytes(sessionID);
+ return formData.lengthInBytes();
uint64_t resultSize;
- callOnMainThreadAndWait([sessionID, formData = formData.isolatedCopy(), &resultSize] {
- resultSize = formData->lengthInBytes(sessionID);
+ callOnMainThreadAndWait([formData = formData.isolatedCopy(), &resultSize] {
+ resultSize = formData->lengthInBytes();
});
return resultSize;
}
@@ -49,7 +49,7 @@
{
uint64_t result = 0;
WTF::switchOn(body, [&] (const Ref<FormData>& formData) {
- result = formDataSize(formData, sessionID());
+ result = formDataSize(formData);
}, [&] (const Ref<SharedBuffer>& buffer) {
result = buffer->size();
}, [] (const std::nullptr_t&) {
Modified: trunk/Source/WebCore/Modules/cache/CacheStorageConnection.h (250044 => 250045)
--- trunk/Source/WebCore/Modules/cache/CacheStorageConnection.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/Modules/cache/CacheStorageConnection.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -57,8 +57,6 @@
virtual void engineRepresentation(CompletionHandler<void(const String&)>&& callback) { callback(String { }); }
virtual void updateQuotaBasedOnSpaceUsage(const ClientOrigin&) { }
- virtual PAL::SessionID sessionID() const = 0;
-
private:
uint64_t computeRealBodySize(const DOMCacheEngine::ResponseBody&);
Modified: trunk/Source/WebCore/Modules/cache/DOMWindowCaches.cpp (250044 => 250045)
--- trunk/Source/WebCore/Modules/cache/DOMWindowCaches.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/Modules/cache/DOMWindowCaches.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -72,7 +72,7 @@
ASSERT(frame());
ASSERT(frame()->document());
if (!m_caches && frame()->page())
- m_caches = DOMCacheStorage::create(*frame()->document(), frame()->page()->cacheStorageProvider().createCacheStorageConnection(frame()->page()->sessionID()));
+ m_caches = DOMCacheStorage::create(*frame()->document(), frame()->page()->cacheStorageProvider().createCacheStorageConnection());
return m_caches.get();
}
Modified: trunk/Source/WebCore/Modules/cache/WorkerCacheStorageConnection.cpp (250044 => 250045)
--- trunk/Source/WebCore/Modules/cache/WorkerCacheStorageConnection.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/Modules/cache/WorkerCacheStorageConnection.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -134,11 +134,6 @@
callOnMainThread([mainThreadConnection = WTFMove(m_mainThreadConnection)]() mutable { });
}
-PAL::SessionID WorkerCacheStorageConnection::sessionID() const
-{
- return m_scope.sessionID();
-}
-
void WorkerCacheStorageConnection::open(const ClientOrigin& origin, const String& cacheName, CacheIdentifierCallback&& callback)
{
uint64_t requestIdentifier = ++m_lastRequestIdentifier;
Modified: trunk/Source/WebCore/Modules/cache/WorkerCacheStorageConnection.h (250044 => 250045)
--- trunk/Source/WebCore/Modules/cache/WorkerCacheStorageConnection.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/Modules/cache/WorkerCacheStorageConnection.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -55,8 +55,6 @@
void reference(uint64_t cacheIdentifier) final;
void dereference(uint64_t cacheIdentifier) final;
- PAL::SessionID sessionID() const final;
-
void doOpen(uint64_t requestIdentifier, const ClientOrigin&, const String& cacheName);
void doRemove(uint64_t requestIdentifier, uint64_t cacheIdentifier);
void doRetrieveCaches(uint64_t requestIdentifier, const ClientOrigin&, uint64_t updateCounter);
Modified: trunk/Source/WebCore/fileapi/Blob.cpp (250044 => 250045)
--- trunk/Source/WebCore/fileapi/Blob.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/fileapi/Blob.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -169,7 +169,7 @@
if (!m_size) {
// FIXME: _javascript_ cannot represent sizes as large as unsigned long long, we need to
// come up with an exception to throw if file size is not representable.
- unsigned long long actualSize = ThreadableBlobRegistry::blobSize(m_sessionID, m_internalURL);
+ unsigned long long actualSize = ThreadableBlobRegistry::blobSize(m_internalURL);
m_size = WTF::isInBounds<long long>(actualSize) ? actualSize : 0;
}
Modified: trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp (250044 => 250045)
--- trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -128,15 +128,15 @@
});
}
-unsigned long long ThreadableBlobRegistry::blobSize(PAL::SessionID sessionID, const URL& url)
+unsigned long long ThreadableBlobRegistry::blobSize(const URL& url)
{
if (isMainThread())
- return blobRegistry().blobSize(sessionID, url);
+ return blobRegistry().blobSize(url);
unsigned long long resultSize;
BinarySemaphore semaphore;
- callOnMainThread([sessionID, url = "" &semaphore, &resultSize] {
- resultSize = blobRegistry().blobSize(sessionID, url);
+ callOnMainThread([url = "" &semaphore, &resultSize] {
+ resultSize = blobRegistry().blobSize(url);
semaphore.signal();
});
semaphore.wait();
Modified: trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h (250044 => 250045)
--- trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/fileapi/ThreadableBlobRegistry.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -51,7 +51,7 @@
static void registerBlobURLForSlice(PAL::SessionID, const URL& newURL, const URL& srcURL, long long start, long long end);
static void unregisterBlobURL(PAL::SessionID, const URL&);
- static unsigned long long blobSize(PAL::SessionID, const URL&);
+ static unsigned long long blobSize(const URL&);
// Returns the origin for the given blob URL. This is because we are not able to embed the unique security origin or the origin of file URL
// in the blob URL.
Modified: trunk/Source/WebCore/loader/cache/KeepaliveRequestTracker.cpp (250044 => 250045)
--- trunk/Source/WebCore/loader/cache/KeepaliveRequestTracker.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/loader/cache/KeepaliveRequestTracker.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -44,7 +44,7 @@
if (!body)
return true;
- uint64_t bodySize = body->lengthInBytes(resource.sessionID());
+ uint64_t bodySize = body->lengthInBytes();
if (m_inflightKeepaliveBytes + bodySize > maxInflightKeepaliveBytes)
return false;
@@ -60,7 +60,7 @@
return;
ASSERT(!m_inflightKeepaliveRequests.contains(&resource));
m_inflightKeepaliveRequests.append(&resource);
- m_inflightKeepaliveBytes += body->lengthInBytes(resource.sessionID());
+ m_inflightKeepaliveBytes += body->lengthInBytes();
ASSERT(m_inflightKeepaliveBytes <= maxInflightKeepaliveBytes);
resource.addClient(*this);
@@ -87,7 +87,7 @@
resource.removeClient(*this);
bool wasRemoved = m_inflightKeepaliveRequests.removeFirst(&resource);
ASSERT_UNUSED(wasRemoved, wasRemoved);
- m_inflightKeepaliveBytes -= resource.resourceRequest().httpBody()->lengthInBytes(resource.sessionID());
+ m_inflightKeepaliveBytes -= resource.resourceRequest().httpBody()->lengthInBytes();
ASSERT(m_inflightKeepaliveBytes <= maxInflightKeepaliveBytes);
}
Modified: trunk/Source/WebCore/page/CacheStorageProvider.h (250044 => 250045)
--- trunk/Source/WebCore/page/CacheStorageProvider.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/page/CacheStorageProvider.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -35,11 +35,10 @@
public:
class DummyCacheStorageConnection final : public WebCore::CacheStorageConnection {
public:
- static Ref<DummyCacheStorageConnection> create(PAL::SessionID sessionID) { return adoptRef(*new DummyCacheStorageConnection(sessionID)); }
+ static Ref<DummyCacheStorageConnection> create() { return adoptRef(*new DummyCacheStorageConnection()); }
private:
- explicit DummyCacheStorageConnection(PAL::SessionID sessionID)
- : m_sessionID(sessionID)
+ DummyCacheStorageConnection()
{
}
@@ -51,13 +50,10 @@
void batchPutOperation(uint64_t, Vector<DOMCacheEngine::Record>&&, DOMCacheEngine::RecordIdentifiersCallback&&) final { }
void reference(uint64_t) final { }
void dereference(uint64_t) final { }
- PAL::SessionID sessionID() const final { return m_sessionID; }
-
- PAL::SessionID m_sessionID;
};
static Ref<CacheStorageProvider> create() { return adoptRef(*new CacheStorageProvider); }
- virtual Ref<CacheStorageConnection> createCacheStorageConnection(PAL::SessionID sessionID) { return DummyCacheStorageConnection::create(sessionID); }
+ virtual Ref<CacheStorageConnection> createCacheStorageConnection() { return DummyCacheStorageConnection::create(); }
virtual ~CacheStorageProvider() { };
protected:
Modified: trunk/Source/WebCore/platform/network/BlobRegistry.h (250044 => 250045)
--- trunk/Source/WebCore/platform/network/BlobRegistry.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/platform/network/BlobRegistry.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -64,7 +64,7 @@
virtual void unregisterBlobURL(PAL::SessionID, const URL&) = 0;
- virtual unsigned long long blobSize(PAL::SessionID, const URL&) = 0;
+ virtual unsigned long long blobSize(const URL&) = 0;
virtual void writeBlobsToTemporaryFiles(PAL::SessionID, const Vector<String>& blobURLs, CompletionHandler<void(Vector<String>&& filePaths)>&&) = 0;
Modified: trunk/Source/WebCore/platform/network/FormData.cpp (250044 => 250045)
--- trunk/Source/WebCore/platform/network/FormData.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/platform/network/FormData.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -149,10 +149,10 @@
});
}
-uint64_t FormDataElement::lengthInBytes(PAL::SessionID sessionID) const
+uint64_t FormDataElement::lengthInBytes() const
{
- return computeLengthInBytes(*this, [&](auto& url) {
- return blobRegistry().blobSize(sessionID, url);
+ return computeLengthInBytes(*this, [](auto& url) {
+ return blobRegistry().blobSize(url);
});
}
@@ -394,12 +394,12 @@
FileSystem::deleteFile(file);
}
-uint64_t FormData::lengthInBytes(PAL::SessionID sessionID) const
+uint64_t FormData::lengthInBytes() const
{
if (!m_lengthInBytes) {
uint64_t length = 0;
for (auto& element : m_elements)
- length += element.lengthInBytes(sessionID);
+ length += element.lengthInBytes();
m_lengthInBytes = length;
}
return *m_lengthInBytes;
Modified: trunk/Source/WebCore/platform/network/FormData.h (250044 => 250045)
--- trunk/Source/WebCore/platform/network/FormData.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/platform/network/FormData.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -52,7 +52,7 @@
: data(EncodedBlobData { blobURL }) { }
uint64_t lengthInBytes(BlobRegistryImpl*) const;
- uint64_t lengthInBytes(PAL::SessionID) const;
+ uint64_t lengthInBytes() const;
FormDataElement isolatedCopy() const;
@@ -251,7 +251,7 @@
return FormURLEncoded;
}
- uint64_t lengthInBytes(PAL::SessionID) const;
+ uint64_t lengthInBytes() const;
WEBCORE_EXPORT URL asBlobURL() const;
Modified: trunk/Source/WebCore/testing/Internals.cpp (250044 => 250045)
--- trunk/Source/WebCore/testing/Internals.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/testing/Internals.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -4892,7 +4892,7 @@
if (!m_cacheStorageConnection) {
if (auto* page = contextDocument()->page())
- m_cacheStorageConnection = page->cacheStorageProvider().createCacheStorageConnection(page->sessionID());
+ m_cacheStorageConnection = page->cacheStorageProvider().createCacheStorageConnection();
if (!m_cacheStorageConnection)
return;
}
@@ -4910,7 +4910,7 @@
if (!m_cacheStorageConnection) {
if (auto* page = contextDocument()->page())
- m_cacheStorageConnection = page->cacheStorageProvider().createCacheStorageConnection(page->sessionID());
+ m_cacheStorageConnection = page->cacheStorageProvider().createCacheStorageConnection();
if (!m_cacheStorageConnection)
return;
}
@@ -4927,7 +4927,7 @@
if (!m_cacheStorageConnection) {
if (auto* page = contextDocument()->page())
- m_cacheStorageConnection = page->cacheStorageProvider().createCacheStorageConnection(page->sessionID());
+ m_cacheStorageConnection = page->cacheStorageProvider().createCacheStorageConnection();
if (!m_cacheStorageConnection)
return;
}
Modified: trunk/Source/WebCore/workers/WorkerMessagingProxy.cpp (250044 => 250045)
--- trunk/Source/WebCore/workers/WorkerMessagingProxy.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/workers/WorkerMessagingProxy.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -139,7 +139,7 @@
{
ASSERT(isMainThread());
auto& document = downcast<Document>(*m_scriptExecutionContext);
- return document.page()->cacheStorageProvider().createCacheStorageConnection(document.page()->sessionID());
+ return document.page()->cacheStorageProvider().createCacheStorageConnection();
}
bool WorkerMessagingProxy::postTaskForModeToWorkerGlobalScope(ScriptExecutionContext::Task&& task, const String& mode)
Modified: trunk/Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.cpp (250044 => 250045)
--- trunk/Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -100,7 +100,6 @@
, m_document(*m_page->mainFrame().document())
, m_serviceWorkerThread(ServiceWorkerThread::create(data, sessionID, WTFMove(userAgent), *this, *this, idbConnectionProxy(m_document), m_document->socketProvider()))
, m_cacheStorageProvider(cacheStorageProvider)
- , m_sessionID(sessionID)
, m_inspectorProxy(*this)
{
static bool addedListener;
@@ -161,7 +160,7 @@
{
ASSERT(isMainThread());
if (!m_cacheStorageConnection)
- m_cacheStorageConnection = m_cacheStorageProvider.createCacheStorageConnection(m_sessionID);
+ m_cacheStorageConnection = m_cacheStorageProvider.createCacheStorageConnection();
return *m_cacheStorageConnection;
}
Modified: trunk/Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.h (250044 => 250045)
--- trunk/Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -95,7 +95,6 @@
Ref<ServiceWorkerThread> m_serviceWorkerThread;
CacheStorageProvider& m_cacheStorageProvider;
RefPtr<CacheStorageConnection> m_cacheStorageConnection;
- PAL::SessionID m_sessionID;
bool m_isTerminatingOrTerminated { false };
ServiceWorkerInspectorProxy m_inspectorProxy;
Modified: trunk/Source/WebCore/xml/XMLHttpRequest.cpp (250044 => 250045)
--- trunk/Source/WebCore/xml/XMLHttpRequest.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebCore/xml/XMLHttpRequest.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -623,7 +623,7 @@
if (m_async) {
m_progressEventThrottle.dispatchProgressEvent(eventNames().loadstartEvent);
if (!m_uploadComplete && m_uploadListenerFlag)
- m_upload->dispatchProgressEvent(eventNames().loadstartEvent, 0, request.httpBody()->lengthInBytes(scriptExecutionContext()->sessionID()));
+ m_upload->dispatchProgressEvent(eventNames().loadstartEvent, 0, request.httpBody()->lengthInBytes());
if (readyState() != OPENED || !m_sendFlag || m_loader)
return { };
Modified: trunk/Source/WebKit/ChangeLog (250044 => 250045)
--- trunk/Source/WebKit/ChangeLog 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/ChangeLog 2019-09-18 18:37:13 UTC (rev 250045)
@@ -1,5 +1,27 @@
2019-09-18 Chris Dumez <[email protected]>
+ CacheStorageProvider::createCacheStorageConnection() does not need to take in a SessionID
+ https://bugs.webkit.org/show_bug.cgi?id=201920
+
+ Reviewed by Geoffrey Garen.
+
+ CacheStorageProvider::createCacheStorageConnection() does not need to take in a SessionID.
+ This sessionID is no longer used now that we have a session per WebProcess.
+
+ * NetworkProcess/NetworkProcessPlatformStrategies.cpp:
+ (WebKit::NetworkProcessPlatformStrategies::createBlobRegistry):
+ * WebProcess/Cache/WebCacheStorageConnection.cpp:
+ (WebKit::WebCacheStorageConnection::sessionID const): Deleted.
+ * WebProcess/Cache/WebCacheStorageConnection.h:
+ * WebProcess/Cache/WebCacheStorageProvider.cpp:
+ (WebKit::WebCacheStorageProvider::createCacheStorageConnection):
+ * WebProcess/Cache/WebCacheStorageProvider.h:
+ * WebProcess/FileAPI/BlobRegistryProxy.cpp:
+ (WebKit::BlobRegistryProxy::blobSize):
+ * WebProcess/FileAPI/BlobRegistryProxy.h:
+
+2019-09-18 Chris Dumez <[email protected]>
+
Drop FrameLoaderClient::sessionID()
https://bugs.webkit.org/show_bug.cgi?id=201916
Modified: trunk/Source/WebKit/NetworkProcess/NetworkProcessPlatformStrategies.cpp (250044 => 250045)
--- trunk/Source/WebKit/NetworkProcess/NetworkProcessPlatformStrategies.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/NetworkProcess/NetworkProcessPlatformStrategies.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -58,7 +58,7 @@
void registerBlobURLOptionallyFileBacked(PAL::SessionID, const URL&, const URL& srcURL, RefPtr<BlobDataFileReference>&&, const String& contentType) final { ASSERT_NOT_REACHED(); }
void registerBlobURLForSlice(PAL::SessionID, const URL&, const URL& srcURL, long long start, long long end) final { ASSERT_NOT_REACHED(); }
void unregisterBlobURL(PAL::SessionID, const URL&) final { ASSERT_NOT_REACHED(); }
- unsigned long long blobSize(PAL::SessionID, const URL&) final { ASSERT_NOT_REACHED(); return 0; }
+ unsigned long long blobSize(const URL&) final { ASSERT_NOT_REACHED(); return 0; }
void writeBlobsToTemporaryFiles(PAL::SessionID, const Vector<String>& blobURLs, CompletionHandler<void(Vector<String>&& filePaths)>&&) final { ASSERT_NOT_REACHED(); }
};
static NeverDestroyed<EmptyBlobRegistry> blobRegistry;
Modified: trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageConnection.cpp (250044 => 250045)
--- trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageConnection.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageConnection.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -110,9 +110,4 @@
connection().send(Messages::NetworkProcess::UpdateQuotaBasedOnSpaceUsageForTesting(WebProcess::singleton().sessionID(), origin), 0);
}
-PAL::SessionID WebCacheStorageConnection::sessionID() const
-{
- return WebProcess::singleton().sessionID();
}
-
-}
Modified: trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageConnection.h (250044 => 250045)
--- trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageConnection.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageConnection.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -66,8 +66,6 @@
void clearMemoryRepresentation(const WebCore::ClientOrigin&, WebCore::DOMCacheEngine::CompletionCallback&&) final;
void engineRepresentation(CompletionHandler<void(const String&)>&&) final;
void updateQuotaBasedOnSpaceUsage(const WebCore::ClientOrigin&) final;
-
- PAL::SessionID sessionID() const final;
WebCacheStorageProvider& m_provider;
};
Modified: trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageProvider.cpp (250044 => 250045)
--- trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageProvider.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageProvider.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -34,9 +34,8 @@
namespace WebKit {
-Ref<WebCore::CacheStorageConnection> WebCacheStorageProvider::createCacheStorageConnection(PAL::SessionID sessionID)
+Ref<WebCore::CacheStorageConnection> WebCacheStorageProvider::createCacheStorageConnection()
{
- ASSERT_UNUSED(sessionID, WebProcess::singleton().sessionID());
if (!m_connection)
m_connection = WebCacheStorageConnection::create(*this);
return *m_connection;
Modified: trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageProvider.h (250044 => 250045)
--- trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageProvider.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/WebProcess/Cache/WebCacheStorageProvider.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -41,7 +41,7 @@
public:
static Ref<WebCacheStorageProvider> create() { return adoptRef(*new WebCacheStorageProvider); }
- Ref<WebCore::CacheStorageConnection> createCacheStorageConnection(PAL::SessionID) final;
+ Ref<WebCore::CacheStorageConnection> createCacheStorageConnection() final;
private:
WebCacheStorageProvider() = default;
Modified: trunk/Source/WebKit/WebProcess/FileAPI/BlobRegistryProxy.cpp (250044 => 250045)
--- trunk/Source/WebKit/WebProcess/FileAPI/BlobRegistryProxy.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/WebProcess/FileAPI/BlobRegistryProxy.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -73,7 +73,7 @@
WebProcess::singleton().ensureNetworkProcessConnection().connection().send(Messages::NetworkConnectionToWebProcess::RegisterBlobURLForSlice(url, srcURL, start, end), 0);
}
-unsigned long long BlobRegistryProxy::blobSize(PAL::SessionID, const URL& url)
+unsigned long long BlobRegistryProxy::blobSize(const URL& url)
{
uint64_t resultSize;
if (!WebProcess::singleton().ensureNetworkProcessConnection().connection().sendSync(Messages::NetworkConnectionToWebProcess::BlobSize(url), Messages::NetworkConnectionToWebProcess::BlobSize::Reply(resultSize), 0))
Modified: trunk/Source/WebKit/WebProcess/FileAPI/BlobRegistryProxy.h (250044 => 250045)
--- trunk/Source/WebKit/WebProcess/FileAPI/BlobRegistryProxy.h 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKit/WebProcess/FileAPI/BlobRegistryProxy.h 2019-09-18 18:37:13 UTC (rev 250045)
@@ -37,7 +37,7 @@
void registerBlobURLOptionallyFileBacked(PAL::SessionID, const URL&, const URL& srcURL, RefPtr<WebCore::BlobDataFileReference>&&, const String& contentType) final;
void unregisterBlobURL(PAL::SessionID, const URL&) final;
void registerBlobURLForSlice(PAL::SessionID, const URL&, const URL& srcURL, long long start, long long end) final;
- unsigned long long blobSize(PAL::SessionID, const URL&) final;
+ unsigned long long blobSize(const URL&) final;
void writeBlobsToTemporaryFiles(PAL::SessionID, const Vector<String>& blobURLs, CompletionHandler<void(Vector<String>&& filePaths)>&&) final;
};
Modified: trunk/Source/WebKitLegacy/mac/ChangeLog (250044 => 250045)
--- trunk/Source/WebKitLegacy/mac/ChangeLog 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKitLegacy/mac/ChangeLog 2019-09-18 18:37:13 UTC (rev 250045)
@@ -1,5 +1,17 @@
2019-09-18 Chris Dumez <[email protected]>
+ CacheStorageProvider::createCacheStorageConnection() does not need to take in a SessionID
+ https://bugs.webkit.org/show_bug.cgi?id=201920
+
+ Reviewed by Geoffrey Garen.
+
+ CacheStorageProvider::createCacheStorageConnection() does not need to take in a SessionID.
+ This sessionID is no longer used now that we have a session per WebProcess.
+
+ * WebCoreSupport/WebPlatformStrategies.mm:
+
+2019-09-18 Chris Dumez <[email protected]>
+
Drop FrameLoaderClient::sessionID()
https://bugs.webkit.org/show_bug.cgi?id=201916
Modified: trunk/Source/WebKitLegacy/mac/WebCoreSupport/WebPlatformStrategies.mm (250044 => 250045)
--- trunk/Source/WebKitLegacy/mac/WebCoreSupport/WebPlatformStrategies.mm 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKitLegacy/mac/WebCoreSupport/WebPlatformStrategies.mm 2019-09-18 18:37:13 UTC (rev 250045)
@@ -70,7 +70,7 @@
void registerBlobURLOptionallyFileBacked(PAL::SessionID, const URL& url, const URL& srcURL, RefPtr<BlobDataFileReference>&& reference, const String& contentType) final { m_blobRegistry.registerBlobURLOptionallyFileBacked(url, srcURL, WTFMove(reference), contentType); }
void registerBlobURLForSlice(PAL::SessionID, const URL& url, const URL& srcURL, long long start, long long end) final { m_blobRegistry.registerBlobURLForSlice(url, srcURL, start, end); }
void unregisterBlobURL(PAL::SessionID, const URL& url) final { m_blobRegistry.unregisterBlobURL(url); }
- unsigned long long blobSize(PAL::SessionID, const URL& url) final { return m_blobRegistry.blobSize(url); }
+ unsigned long long blobSize(const URL& url) final { return m_blobRegistry.blobSize(url); }
void writeBlobsToTemporaryFiles(PAL::SessionID, const Vector<String>& blobURLs, CompletionHandler<void(Vector<String>&& filePaths)>&& completionHandler) final { m_blobRegistry.writeBlobsToTemporaryFiles(blobURLs, WTFMove(completionHandler)); }
BlobRegistryImpl* blobRegistryImpl() final { return &m_blobRegistry; }
Modified: trunk/Source/WebKitLegacy/win/WebCoreSupport/WebPlatformStrategies.cpp (250044 => 250045)
--- trunk/Source/WebKitLegacy/win/WebCoreSupport/WebPlatformStrategies.cpp 2019-09-18 18:05:20 UTC (rev 250044)
+++ trunk/Source/WebKitLegacy/win/WebCoreSupport/WebPlatformStrategies.cpp 2019-09-18 18:37:13 UTC (rev 250045)
@@ -68,7 +68,7 @@
void registerBlobURLOptionallyFileBacked(PAL::SessionID, const URL& url, const URL& srcURL, RefPtr<BlobDataFileReference>&& reference, const String& contentType) final { m_blobRegistry.registerBlobURLOptionallyFileBacked(url, srcURL, WTFMove(reference), contentType); }
void registerBlobURLForSlice(PAL::SessionID, const URL& url, const URL& srcURL, long long start, long long end) final { m_blobRegistry.registerBlobURLForSlice(url, srcURL, start, end); }
void unregisterBlobURL(PAL::SessionID, const URL& url) final { m_blobRegistry.unregisterBlobURL(url); }
- unsigned long long blobSize(PAL::SessionID, const URL& url) final { return m_blobRegistry.blobSize(url); }
+ unsigned long long blobSize(const URL& url) final { return m_blobRegistry.blobSize(url); }
void writeBlobsToTemporaryFiles(PAL::SessionID, const Vector<String>& blobURLs, CompletionHandler<void(Vector<String>&& filePaths)>&& completionHandler) final { m_blobRegistry.writeBlobsToTemporaryFiles(blobURLs, WTFMove(completionHandler)); }
BlobRegistryImpl* blobRegistryImpl() final { return &m_blobRegistry; }