tree: fa07f320182a80d510a45649fca36aad6f239ab6 [path history] [tgz]
  1. cors/
  2. fetch/
  3. testing/
  4. allowed_by_nosniff.cc
  5. allowed_by_nosniff.h
  6. allowed_by_nosniff_test.cc
  7. BUILD.gn
  8. child_url_loader_factory_bundle.cc
  9. DEPS
  10. DIR_METADATA
  11. internet_disconnected_url_loader.cc
  12. internet_disconnected_url_loader.h
  13. link_header.cc
  14. link_header.h
  15. link_header_test.cc
  16. mixed_content.cc
  17. mixed_content.h
  18. mixed_content_autoupgrade_status.h
  19. OWNERS
  20. README.md
  21. static_data_navigation_body_loader.cc
  22. static_data_navigation_body_loader.h
  23. static_data_navigation_body_loader_test.cc
  24. subresource_integrity.cc
  25. subresource_integrity.h
  26. subresource_integrity_test.cc
  27. tracked_child_url_loader_factory_bundle.cc
  28. web_url_request_extra_data.cc
  29. web_url_request_util.cc
third_party/blink/renderer/platform/loader/README.md

platform/loader/

Loading and Freezing

Loaders (i.e., blink::ResourceLoaders and related objects) run on unfreezable task runners, which means even when the associated page is frozen a loader is still running. This is because having frozen loaders for a long time confuses the network service and the resource scheduler in it. On the other hand, it would be difficult for blink code authors to handle the situation where the loading module is working while everything else is frozen correctly, given that loading experts are not necessarily freezing experts. To mitigate the pain, we run only part of the loading module when the page is frozen. Namely,

  • blink::MojoURLLoaderClient
  • blink::ResponseBodyLoader
  • blink::ResourceRequestClient implementations
  • blink::ThrottlingURLLoader implementations
  • blink::BackForwardCacheLoaderHelper implementations

may run when the associated context is frozen, and other modules won't run (except for the case where they are called from outside of the loading module). To guarantee this, blink::ResourceFetcher::SetDefersLoading needs to be called when the associated context gets frozen and unfrozen.

Directory organization

cors

Contains Cross-Origin Resource Sharing (CORS) related files. Some functions in this directory will be removed once CORS support is moved to //services/network. Please contact {kinuko,toyoshim}@chromium.org when you need to depend on this directory from new code.

fetch

Contains files for low-level loading APIs. The PLATFORM_EXPORT macro is needed to use them from core/. Otherwise they can be used only in platform/.

The directory conceptually implements https://fetch.spec.whatwg.org/#fetching (with lower-level components such as the network service). See also: slides describing the relationship with the fetch spec

testing

Contains helper files for testing that are available in both blink_platform_unittests and blink_unittests. These files are built as a part of the platform:test_support static library.