-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fetch/delete data store identifiers on a background thread #10826
Fetch/delete data store identifiers on a background thread #10826
Conversation
EWS run on previous version of this PR (hash d72f566) |
Source/WebKit/UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm
Outdated
Show resolved
Hide resolved
Source/WebKit/UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm
Outdated
Show resolved
Hide resolved
d72f566
to
e4619f9
Compare
EWS run on current version of this PR (hash e4619f9) |
EWS run on previous version of this PR (hash e4619f9) |
e4619f9
to
e76a28d
Compare
EWS run on previous version of this PR (hash e76a28d) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
completionHandler(WTFMove(identifiers)); | ||
websiteDataStoreIOQueue().dispatch([completionHandler = WTFMove(completionHandler), directory = defaultWebsiteDataStoreRootDirectory().isolatedCopy()]() mutable { | ||
Vector<UUID> identifiers; | ||
for (auto& identifierString : FileSystem::listDirectory(directory)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be nice to use compactMap() for this. It would be a bit shorter and more efficient.
Likely something like:
auto identifiers = WTF::compactMap(FileSystem::listDirectory(directory), [](auto& identifierString) { return UUID::parse(identifierString); });
e76a28d
to
482f28c
Compare
EWS run on previous version of this PR (hash 482f28c) |
482f28c
to
59ba50c
Compare
EWS run on current version of this PR (hash 59ba50c) |
59ba50c
to
a17f673
Compare
https://bugs.webkit.org/show_bug.cgi?id=253113 rdar://106051983 Reviewed by Chris Dumez. These involves disk operations that should be performed on background thread. * Source/WebKit/UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm: (WebKit::WebsiteDataStore::fetchAllDataStoreIdentifiers): (WebKit::WebsiteDataStore::removeDataStoreWithIdentifier): * Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp: (WebKit::WebsiteDataStore::websiteDataStoreIOQueue): * Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h: Canonical link: https://commits.webkit.org/261187@main
a17f673
to
b085855
Compare
Committed 261187@main (b085855): https://commits.webkit.org/261187@main Reviewed commits have been landed. Closing PR #10826 and removing active labels. |
b085855
59ba50c
π§ͺ wpe-wk2π§ͺ ios-wk2π§ͺ api-iosπ§ͺ api-gtkπ§ͺ mac-wk2-stressπ watch-sim