Bug 240125 - [WP] Wait for Launch Services database after Network process connection has been established
Summary: [WP] Wait for Launch Services database after Network process connection has b...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-05-05 09:21 PDT by Per Arne Vollan
Modified: 2022-05-06 10:38 PDT (History)
4 users (show)

See Also:


Attachments
Patch (5.15 KB, patch)
2022-05-05 09:28 PDT, Per Arne Vollan
no flags Details | Formatted Diff | Diff
Patch (5.24 KB, patch)
2022-05-05 09:30 PDT, Per Arne Vollan
no flags Details | Formatted Diff | Diff
Patch (5.22 KB, patch)
2022-05-05 09:35 PDT, Per Arne Vollan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Per Arne Vollan 2022-05-05 09:21:44 PDT
Since the Launch Services database is provided to the WebContent process by the Network process, it makes sense to wait for the database when we're certain that the Network process is running. This should fix main thread hangs in the cases where we before started waiting for the database before the Network process had launched. To support this move, we also need to delay the initialization of accessibility in NSApplication, since that depends on having the database available. This is now being done in WebPage::platformInitializeAccessibility, which is a natural place for this initialization to take place.
Comment 1 Per Arne Vollan 2022-05-05 09:28:19 PDT
Created attachment 458880 [details]
Patch
Comment 2 Per Arne Vollan 2022-05-05 09:30:34 PDT
Created attachment 458881 [details]
Patch
Comment 3 Per Arne Vollan 2022-05-05 09:35:35 PDT
Created attachment 458883 [details]
Patch
Comment 4 Per Arne Vollan 2022-05-05 09:39:15 PDT
<rdar://92107043>
Comment 5 Geoffrey Garen 2022-05-05 15:03:50 PDT
Comment on attachment 458883 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=458883&action=review

r=me

> Source/WebKit/WebProcess/WebProcess.cpp:1201
> +        // The NSApplication initialization is being done in [NSApplication _accessibilityInitialize]

No need to call accessibilityInitialize here.
Comment 6 Per Arne Vollan 2022-05-06 07:45:01 PDT
(In reply to Geoffrey Garen from comment #5)
> Comment on attachment 458883 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=458883&action=review
> 
> r=me
> 
> > Source/WebKit/WebProcess/WebProcess.cpp:1201
> > +        // The NSApplication initialization is being done in [NSApplication _accessibilityInitialize]
> 
> No need to call accessibilityInitialize here.

Looking closer, this actually seems to be inside a comment. Line wrapping made it look like a separate statement when we last looked at this.

Thanks for reviewing!
Comment 7 EWS 2022-05-06 08:24:35 PDT
Committed r293892 (250350@main): <https://commits.webkit.org/250350@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 458883 [details].
Comment 8 Geoffrey Garen 2022-05-06 10:17:00 PDT
Haha, that's the last time I review a patch on my phone! :P
Comment 9 Per Arne Vollan 2022-05-06 10:38:48 PDT
(In reply to Geoffrey Garen from comment #8)
> Haha, that's the last time I review a patch on my phone! :P

:)