Bug 203103 - DatabaseContext should not prevent entering the back/forward cache
Summary: DatabaseContext should not prevent entering the back/forward cache
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
: 159379 (view as bug list)
Depends on:
Blocks: 202293
  Show dependency treegraph
 
Reported: 2019-10-17 09:56 PDT by Chris Dumez
Modified: 2020-01-16 16:02 PST (History)
8 users (show)

See Also:


Attachments
Patch (15.13 KB, patch)
2019-10-24 13:36 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Patch (15.37 KB, patch)
2019-10-27 16:34 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Patch (18.11 KB, patch)
2019-10-28 12:33 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2019-10-17 09:56:10 PDT
DatabaseContext should not prevent entering the back/forward cache.
Comment 1 Radar WebKit Bug Importer 2019-10-24 13:34:20 PDT
<rdar://problem/56592193>
Comment 2 Chris Dumez 2019-10-24 13:35:56 PDT
*** Bug 159379 has been marked as a duplicate of this bug. ***
Comment 3 Chris Dumez 2019-10-24 13:36:07 PDT
Created attachment 381841 [details]
Patch
Comment 4 Geoffrey Garen 2019-10-24 21:28:49 PDT
Comment on attachment 381841 [details]
Patch

r=me
Comment 5 WebKit Commit Bot 2019-10-24 22:36:09 PDT
The commit-queue encountered the following flaky tests while processing attachment 381841 [details]:

The commit-queue is continuing to process your patch.
Comment 6 WebKit Commit Bot 2019-10-24 22:36:26 PDT
The commit-queue encountered the following flaky tests while processing attachment 381841 [details]:

imported/w3c/web-platform-tests/svg/text/visualtests/text-inline-size-003-visual.svg bug 203172 (author: sabouhallawa@apple.com)
fast/history/page-cache-webdatabase-pending-transaction.html bug 203399 (author: cdumez@apple.com)
The commit-queue is continuing to process your patch.
Comment 7 WebKit Commit Bot 2019-10-25 01:14:31 PDT
Comment on attachment 381841 [details]
Patch

Clearing flags on attachment: 381841

Committed r251586: <https://trac.webkit.org/changeset/251586>
Comment 8 WebKit Commit Bot 2019-10-25 01:14:33 PDT
All reviewed patches have been landed.  Closing bug.
Comment 9 Chris Dumez 2019-10-25 08:44:26 PDT
Reverted r251586 for reason:

New test is flaky

Committed r251592: <https://trac.webkit.org/changeset/251592>
Comment 10 Chris Dumez 2019-10-25 09:11:41 PDT
Looks like queueing JS callbacks in not sufficient because Database threads currently get terminated on navigation and may therefore not have time to schedule their callbacks:
1   0x7243d44e1 WTF::MessageQueue<WebCore::DatabaseTask>::kill()
2   0x7243d0ac4 WebCore::DatabaseThread::requestTermination(WebCore::DatabaseTaskSynchronizer*)
3   0x7243d0988 WebCore::DatabaseContext::stopDatabases(WebCore::DatabaseTaskSynchronizer*)
4   0x7243d2be3 WebCore::DatabaseManager::stopDatabases(WebCore::Document&, WebCore::DatabaseTaskSynchronizer*)
5   0x7256d2e39 WebCore::FrameLoader::stopLoading(WebCore::UnloadEventPolicy)
Comment 11 Chris Dumez 2019-10-27 16:34:58 PDT
Created attachment 382042 [details]
Patch
Comment 12 Chris Dumez 2019-10-28 12:33:58 PDT
Created attachment 382095 [details]
Patch
Comment 13 Chris Dumez 2019-10-30 15:50:37 PDT
ping review?
Comment 14 Chris Dumez 2019-11-04 12:53:47 PST
ping review?
Comment 15 Geoffrey Garen 2019-11-05 10:46:05 PST
Comment on attachment 382095 [details]
Patch

r=me

Pretty sure WebDatabase is fully disabled these days, so I guess this is an example of why it would be good to remove the code entirely soon.
Comment 16 WebKit Commit Bot 2019-11-05 11:15:25 PST
Comment on attachment 382095 [details]
Patch

Clearing flags on attachment: 382095

Committed r252064: <https://trac.webkit.org/changeset/252064>
Comment 17 WebKit Commit Bot 2019-11-05 11:15:27 PST
All reviewed patches have been landed.  Closing bug.