Bug 193243

Summary: Stop using NetworkProcess::singleton in NetworkCache code
Product: WebKit Reporter: Alex Christensen <achristensen>
Component: New BugsAssignee: Alex Christensen <achristensen>
Status: RESOLVED FIXED    
Severity: Normal CC: aestes, beidson, bfulgham, cdumez, cgarcia, ews-watchlist, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch bfulgham: review+

Alex Christensen
Reported 2019-01-08 09:44:31 PST
Stop using NetworkProcess::singleton in NetworkCache code
Attachments
Patch (20.26 KB, patch)
2019-01-08 09:44 PST, Alex Christensen
no flags
Patch (21.02 KB, patch)
2019-01-08 10:11 PST, Alex Christensen
bfulgham: review+
Alex Christensen
Comment 1 2019-01-08 09:44:41 PST
Alex Christensen
Comment 2 2019-01-08 10:11:07 PST
Brent Fulgham
Comment 3 2019-01-08 13:17:41 PST
Comment on attachment 358609 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=358609&action=review > Source/WebKit/ChangeLog:4 > + https://bugs.webkit.org/show_bug.cgi?id=193243 Missing radar... > Source/WebKit/NetworkProcess/cache/NetworkCache.h:166 > + Ref<NetworkProcess> m_networkProcess; This means that the NetworkCache will keep the NetworkProcess alive. Is that the right ownership model? (I'm not disagreeing, just want to be sure that's correct). Otherwise we could make this a WeakPtr. However, since it was a singleton before, I assume the expectation is we never have a cache without a process (and vice versa).
Chris Dumez
Comment 4 2019-01-08 13:18:58 PST
(In reply to Brent Fulgham from comment #3) > Comment on attachment 358609 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=358609&action=review > > > Source/WebKit/ChangeLog:4 > > + https://bugs.webkit.org/show_bug.cgi?id=193243 > > Missing radar... We do not have a requirement have having a radar, do we? radars get auto-filed when the patch gets committed.
Alex Christensen
Comment 5 2019-01-08 13:22:20 PST
The NetworkCache will soon be a member of the NetworkSession, which should keep the NetworkProcess alive. Thanks for the review.
Alex Christensen
Comment 6 2019-01-08 13:23:11 PST
Radar WebKit Bug Importer
Comment 7 2019-01-08 13:24:28 PST
Note You need to log in before you can comment on or make changes to this bug.