Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use ResourceLoader to load appcache manifest
https://bugs.webkit.org/show_bug.cgi?id=182861 Patch by Youenn Fablet <youenn@apple.com> on 2018-02-21 Reviewed by Alex Christensen. Source/WebCore: Covered by updated tests. Add ApplicationCacheResourceLoader to load an ApplicationCacheResource from a ResourceLoader. Make use of it to load the app cache manifest. Future work should load entries using the same loader. Remove manifest handle. Ensure that DocumentLoader does not register the manifest resource loader as its lifetime is handled by its ApplicationCacheGroup. Add a ResourceLoader option to bypass the application cache. Use it for manifest loading. * Sources.txt: * WebCore.xcodeproj/project.pbxproj: * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::addSubresourceLoader): * loader/ResourceLoaderOptions.h: * loader/appcache/ApplicationCacheGroup.cpp: (WebCore::ApplicationCacheGroup::stopLoading): (WebCore::ApplicationCacheGroup::update): (WebCore::ApplicationCacheGroup::createRequest): (WebCore::ApplicationCacheGroup::didReceiveResponseAsync): (WebCore::ApplicationCacheGroup::didReceiveData): (WebCore::ApplicationCacheGroup::didFinishLoading): (WebCore::ApplicationCacheGroup::didFail): (WebCore::ApplicationCacheGroup::didFinishLoadingManifest): (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete): * loader/appcache/ApplicationCacheGroup.h: * loader/appcache/ApplicationCacheHost.cpp: (WebCore::ApplicationCacheHost::maybeLoadResource): (WebCore::ApplicationCacheHost::maybeLoadFallbackForRedirect): (WebCore::ApplicationCacheHost::maybeLoadFallbackForResponse): (WebCore::ApplicationCacheHost::maybeLoadFallbackForError): * loader/appcache/ApplicationCacheResourceLoader.cpp: Added. * loader/appcache/ApplicationCacheResourceLoader.h: Added. LayoutTests: * http/tests/appcache/fail-on-update-2-expected.txt: * http/tests/appcache/manifest-redirect-2-expected.txt: * http/tests/appcache/offline-access-expected.txt: Canonical link: https://commits.webkit.org/198767@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@228892 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
1 parent
ed4f541
commit 8d64756
Showing
14 changed files
with
377 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
CONSOLE MESSAGE: line 1: ApplicationCache is deprecated. Please use ServiceWorkers instead. | ||
CONSOLE MESSAGE: Application Cache manifest could not be fetched, because the manifest had a 404 response. | ||
CONSOLE MESSAGE: line 1: ApplicationCache is deprecated. Please use ServiceWorkers instead. | ||
CONSOLE MESSAGE: line 1: ApplicationCache is deprecated. Please use ServiceWorkers instead. | ||
CONSOLE MESSAGE: Application Cache manifest could not be fetched, because the manifest had a 404 response. | ||
CONSOLE MESSAGE: line 1: ApplicationCache is deprecated. Please use ServiceWorkers instead. | ||
CONSOLE MESSAGE: line 1: ApplicationCache is deprecated. Please use ServiceWorkers instead. | ||
SUCCESS: No crash. |
1 change: 1 addition & 0 deletions
1
LayoutTests/http/tests/appcache/manifest-redirect-2-expected.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.