⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 282228 in webkit


Ignore:
Timestamp:
Sep 9, 2021, 11:04:30 AM (5 years ago)
Author:
Russell Epstein
Message:

Cherry-pick r282174. rdar://problem/82931245

Remove responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection
​https://bugs.webkit.org/show_bug.cgi?id=230016
rdar://problem/80760179

Reviewed by Chris Dumez.

We've seen evidence that network process may be blocked in initializeNetworkProcess. Since we have a 3-second
responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection, blocked network process will be killed
and a new network process will be launched for getting connection. However, the new network process may get
stuck in initializeNetworkProcess too. In this case, web process will crash for not being able to get network
process connection.

  • UIProcess/Network/NetworkProcessProxy.cpp: (WebKit::NetworkProcessProxy::getNetworkProcessConnection):
  • UIProcess/WebsiteData/WebsiteDataStore.cpp: change RELEASE_ASSERT_NOT_REACHED_WITH_MESSAGE to RELEASE_LOG_ERROR as the message is not printed in non-debug build. (WebKit::WebsiteDataStore::getNetworkProcessConnection):

git-svn-id: ​https://svn.webkit.org/repository/webkit/trunk@282174 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Location:
branches/safari-612-branch/Source/WebKit
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/safari-612-branch/Source/WebKit/ChangeLog

    r282154 r282228  
     12021-09-09  Russell Epstein  <repstein@apple.com>
     2
     3        Cherry-pick r282174. rdar://problem/82931245
     4
     5    Remove responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection
     6    https://bugs.webkit.org/show_bug.cgi?id=230016
     7    rdar://problem/80760179
     8   
     9    Reviewed by Chris Dumez.
     10   
     11    We've seen evidence that network process may be blocked in initializeNetworkProcess. Since we have a 3-second
     12    responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection, blocked network process will be killed
     13    and a new network process will be launched for getting connection. However, the new network process may get
     14    stuck in initializeNetworkProcess too. In this case, web process will crash for not being able to get network
     15    process connection.
     16   
     17    * UIProcess/Network/NetworkProcessProxy.cpp:
     18    (WebKit::NetworkProcessProxy::getNetworkProcessConnection):
     19    * UIProcess/WebsiteData/WebsiteDataStore.cpp: change RELEASE_ASSERT_NOT_REACHED_WITH_MESSAGE to
     20    RELEASE_LOG_ERROR as the message is not printed in non-debug build.
     21    (WebKit::WebsiteDataStore::getNetworkProcessConnection):
     22   
     23   
     24    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@282174 268f45cc-cd09-0410-ab3c-d52691b4dbfc
     25
     26    2021-09-08  Sihui Liu  <sihui_liu@apple.com>
     27
     28            Remove responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection
     29            https://bugs.webkit.org/show_bug.cgi?id=230016
     30            rdar://problem/80760179
     31
     32            Reviewed by Chris Dumez.
     33
     34            We've seen evidence that network process may be blocked in initializeNetworkProcess. Since we have a 3-second
     35            responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection, blocked network process will be killed
     36            and a new network process will be launched for getting connection. However, the new network process may get
     37            stuck in initializeNetworkProcess too. In this case, web process will crash for not being able to get network
     38            process connection.
     39
     40            * UIProcess/Network/NetworkProcessProxy.cpp:
     41            (WebKit::NetworkProcessProxy::getNetworkProcessConnection):
     42            * UIProcess/WebsiteData/WebsiteDataStore.cpp: change RELEASE_ASSERT_NOT_REACHED_WITH_MESSAGE to
     43            RELEASE_LOG_ERROR as the message is not printed in non-debug build.
     44            (WebKit::WebsiteDataStore::getNetworkProcessConnection):
     45
    1462021-09-08  Alan Coon  <alancoon@apple.com>
    247
  • branches/safari-612-branch/Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp

    r281096 r282228  
    251251{
    252252    RELEASE_LOG(ProcessSuspension, "%p - NetworkProcessProxy is taking a background assertion because a web process is requesting a connection", this);
    253     startResponsivenessTimer(UseLazyStop::No);
     253    if (!isLaunching())
     254        startResponsivenessTimer(UseLazyStop::No);
    254255    sendWithAsyncReply(Messages::NetworkProcess::CreateNetworkConnectionToWebProcess { webProcessProxy.coreProcessIdentifier(), webProcessProxy.sessionID() }, [this, weakThis = makeWeakPtr(*this), reply = WTFMove(reply)](auto&& identifier, auto cookieAcceptPolicy) mutable {
    255256        if (!weakThis) {
  • branches/safari-612-branch/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp

    r281199 r282228  
    17461746                    networkProcessState = networkProcessProxy->stateString();
    17471747                }
    1748                 RELEASE_ASSERT_NOT_REACHED_WITH_MESSAGE("WebsiteDataStore::getNetworkProcessConnection: Failed to get connection - networkProcessProxy=%p, networkProcessIdentifier=%d, processState=%s, webProcessProxy=%p, webProcessIdentifier=%d", networkProcessProxy.get(), networkProcessIdentifier, networkProcessState.utf8().data(), webProcessProxy.get(), webProcessProxy->processIdentifier());
     1748                RELEASE_LOG_ERROR(Process, "WebsiteDataStore::getNetworkProcessConnection: Failed to get connection - networkProcessProxy=%p, networkProcessIdentifier=%d, processState=%s, webProcessProxy=%p, webProcessIdentifier=%d", networkProcessProxy.get(), networkProcessIdentifier, networkProcessState.utf8().data(), webProcessProxy.get(), webProcessProxy->processIdentifier());
     1749                RELEASE_ASSERT_NOT_REACHED();
    17491750#endif
    17501751            };
Note: See TracChangeset for help on using the changeset viewer.