• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..16-Feb-2021-

proto/H16-Feb-2021-200167

store/H16-Feb-2021-2,0291,468

tasks/H16-Feb-2021-7,0515,133

BUILD.gnH A D16-Feb-20218.8 KiB274262

DEPSH A D16-Feb-2021333 1514

README.mdH A D16-Feb-20211.7 KiB4431

fake_suggestions_provider.ccH A D16-Feb-20211.2 KiB4227

fake_suggestions_provider.hH A D16-Feb-20211.4 KiB4226

generate_page_bundle_request.ccH A D16-Feb-20212.8 KiB7356

generate_page_bundle_request.hH A D16-Feb-20211.6 KiB5235

generate_page_bundle_request_unittest.ccH A D16-Feb-20216.5 KiB171134

get_operation_request.ccH A D16-Feb-20212.2 KiB6246

get_operation_request.hH A D16-Feb-20211.7 KiB5531

get_operation_request_unittest.ccH A D16-Feb-20214.7 KiB12791

mock_prefetch_item_generator.ccH A D16-Feb-20213.8 KiB12088

mock_prefetch_item_generator.hH A D16-Feb-20213.6 KiB9155

offline_metrics_collector.hH A D16-Feb-20212 KiB5316

prefetch_background_task.ccH A D16-Feb-20213.3 KiB8563

prefetch_background_task.hH A D16-Feb-20211.4 KiB4422

prefetch_background_task_handler.hH A D16-Feb-20211.6 KiB4918

prefetch_dispatcher.hH A D16-Feb-20216.3 KiB13750

prefetch_dispatcher_impl.ccH A D16-Feb-202122 KiB555431

prefetch_dispatcher_impl.hH A D16-Feb-20216.8 KiB155106

prefetch_dispatcher_impl_unittest.ccH A D16-Feb-202134.8 KiB918666

prefetch_download_flow_unittest.ccH A D16-Feb-20217.9 KiB210148

prefetch_downloader.hH A D16-Feb-20212.6 KiB7035

prefetch_downloader_impl.ccH A D16-Feb-202110.3 KiB256216

prefetch_downloader_impl.hH A D16-Feb-20213.6 KiB10668

prefetch_downloader_impl_unittest.ccH A D16-Feb-20217.5 KiB195157

prefetch_gcm_app_handler.ccH A D16-Feb-20212.2 KiB6948

prefetch_gcm_app_handler.hH A D16-Feb-20211.9 KiB5635

prefetch_gcm_app_handler_unittest.ccH A D16-Feb-20212.5 KiB7551

prefetch_gcm_handler.hH A D16-Feb-20211.1 KiB4019

prefetch_importer.ccH A D16-Feb-2021604 189

prefetch_importer.hH A D16-Feb-20211.9 KiB5321

prefetch_importer_impl.ccH A D16-Feb-20215.5 KiB151107

prefetch_importer_impl.hH A D16-Feb-20211.6 KiB5133

prefetch_importer_impl_unittest.ccH A D16-Feb-20215.6 KiB167127

prefetch_item.ccH A D16-Feb-2021619 2210

prefetch_item.hH A D16-Feb-20215.2 KiB14048

prefetch_item_unittest.ccH A D16-Feb-20215.3 KiB152101

prefetch_network_request_factory.hH A D16-Feb-20212.3 KiB6130

prefetch_network_request_factory_impl.ccH A D16-Feb-20216.5 KiB174135

prefetch_network_request_factory_impl.hH A D16-Feb-20213.7 KiB10467

prefetch_network_request_factory_impl_unittest.ccH A D16-Feb-202111.2 KiB267178

prefetch_prefs.ccH A D16-Feb-20214.7 KiB137109

prefetch_prefs.hH A D16-Feb-20213.2 KiB8228

prefetch_prefs_unittest.ccH A D16-Feb-20216 KiB158102

prefetch_proto_utils.ccH A D16-Feb-20214.5 KiB145115

prefetch_proto_utils.hH A D16-Feb-2021932 2511

prefetch_request_fetcher.ccH A D16-Feb-20216.4 KiB174141

prefetch_request_fetcher.hH A D16-Feb-20212.5 KiB7448

prefetch_request_fetcher_unittest.ccH A D16-Feb-20217 KiB184154

prefetch_request_operation_response_unittest.ccH A D16-Feb-202116.6 KiB431352

prefetch_request_test_base.ccH A D16-Feb-20214.1 KiB11388

prefetch_request_test_base.hH A D16-Feb-20212.3 KiB6746

prefetch_server_urls.ccH A D16-Feb-20213.2 KiB8660

prefetch_server_urls.hH A D16-Feb-20211.3 KiB3618

prefetch_server_urls_unittest.ccH A D16-Feb-20212.1 KiB5941

prefetch_service.hH A D16-Feb-20213.9 KiB10448

prefetch_service_impl.ccH A D16-Feb-20215.9 KiB174137

prefetch_service_impl.hH A D16-Feb-20214.1 KiB10470

prefetch_service_impl_unittest.ccH A D16-Feb-2021763 2212

prefetch_service_test_taco.ccH A D16-Feb-20217.2 KiB190154

prefetch_service_test_taco.hH A D16-Feb-20214.7 KiB11876

prefetch_types.ccH A D16-Feb-20219.9 KiB265236

prefetch_types.hH A D16-Feb-202112 KiB316149

server_forbidden_check_request.ccH A D16-Feb-20212.1 KiB5440

server_forbidden_check_request.hH A D16-Feb-20211.3 KiB2811

server_forbidden_check_request_unittest.ccH A D16-Feb-20213.9 KiB11480

stub_prefetch_service.ccH A D16-Feb-20211.8 KiB7449

stub_prefetch_service.hH A D16-Feb-20211.6 KiB4028

suggestions_provider.ccH A D16-Feb-2021555 187

suggestions_provider.hH A D16-Feb-20212.3 KiB6630

test_download_client.ccH A D16-Feb-2021954 2918

test_download_client.hH A D16-Feb-20211.1 KiB3622

test_download_service.ccH A D16-Feb-20213.7 KiB11491

test_download_service.hH A D16-Feb-20212.2 KiB5840

test_offline_metrics_collector.hH A D16-Feb-20211.1 KiB3219

test_prefetch_dispatcher.ccH A D16-Feb-20212.8 KiB8863

test_prefetch_dispatcher.hH A D16-Feb-20212.8 KiB7356

test_prefetch_downloader.ccH A D16-Feb-20211.7 KiB5334

test_prefetch_downloader.hH A D16-Feb-20212.1 KiB6043

test_prefetch_gcm_handler.ccH A D16-Feb-2021678 2212

test_prefetch_gcm_handler.hH A D16-Feb-2021936 3017

test_prefetch_importer.ccH A D16-Feb-2021745 2412

test_prefetch_importer.hH A D16-Feb-2021952 2916

test_prefetch_network_request_factory.ccH A D16-Feb-20211.3 KiB3624

test_prefetch_network_request_factory.hH A D16-Feb-20211.3 KiB3823

test_util.ccH A D16-Feb-20213.1 KiB7358

visuals_fetch_by_url.ccH A D16-Feb-20213.1 KiB8971

visuals_fetch_by_url.hH A D16-Feb-20211.2 KiB3719

README.md

1# Prefetching Offline Pages
2
3## Architecture overview
4
5### PrefetchService
6
7Is the ownership holder for the main components of the prefetching system and
8controls their lifetime.
9
10### PrefetchDispatcher
11
12Manages the prefetching pipeline tasks. It receives signals from external
13clients and creates the appropriate tasks to execute them. It _might_ at some
14point execute advanced task management operations like canceling queued tasks or
15changing their order of execution.
16
17### \*Task(s) (i.e. AddUniqueUrlsTask)
18
19They are the main wrapper of pipeline steps and interact with different
20abstracted components (Downloads, persistent store, GCM, etc) to execute them.
21They implement TaskQueue's Task API so that they can be exclusively executed.
22
23## Prefetch store
24
25* The PrefetchStore depends publicly on SQL and acts as a gateway to the SQLite
26  database.
27* It defines specific method signatures used to create callbacks that are passed
28  to the store for the proper execution of SQL commands.
29* SQL access resources are granted to those callbacks only when needed and in an
30  appropriate environment (correct thread, etc).
31* Pipeline tasks define methods following those signatures that contain the SQL
32  commands they require to do their work.
33* Tasks receive a pointer to the store to be able to execute their SQL commands.
34
35More detailed instructions of how to use Prefetch store can be found [here](
36store/README.md)
37
38## Development guidelines
39
40* Implementations that are injected dependencies during service creation should
41  have lightweight construction and postpone heavier initialization (i.e. DB
42  connection) to a later moment. Lazy initialization upon first actual usage is
43  recommended.
44