Firefox OS/Cloud Storage: Difference between revisions

Update Cache Architecture
(Change the resolution of cache architecture)
(Update Cache Architecture)
Line 29: Line 29:
** Cache store is a subset of cloud storage, so Cache system still can provide cached file content from cache store even no network connection available.
** Cache store is a subset of cloud storage, so Cache system still can provide cached file content from cache store even no network connection available.
=== Architecture ===
=== Architecture ===
[[File:Cache Architechture.png|thumbnail|Cache Architecture|500px]]
[[File:CacheArchitechture.png|thumbnail|Cache Architecture|500px]]
* '''Cache Manager'''
* '''Cache Manager'''
** Dispatch the request from Cloud Storage Interface to Data/Meta Cache first
** Block-based data management
** Dispatch low-level file operation from FUSE to Data/Meta Cache first
** Get data from Web Storage Manager if there is no data existed in Cache.
** Get data from Web Storage Manager if there is no data existed in Cache.
* '''Cloud Storage Interface'''
** The interface for using Cloud Storage cache is a general design. This can be used in JS Library or Gecko implementation.
* '''Meta Cache'''
* '''Meta Cache'''
** Each file has its meta data like mdate, cdate, size, etc. These information should be cached.
** Metadata for each file (mdate, cdate, size, etc.) should be cached in memory or Indexed DB.
* '''Data Cache'''
* '''Data Cache'''
** Data Cache should store a file content requested by user for each file in order to avoid extra network transaction.
** Data Cache should store a file content requested by user for each file in order to avoid extra network transaction.
30

edits