Project

General

Profile

Actions

FileManager » History » Revision 5

« Previous | Revision 5/7 (diff) | Next »
Greg Burri, 05/28/2010 02:57 AM


FileManager

Algorithms

Sharing

There is two type of shared directory :

  1. Readonly : The content will only be uploaded.
  2. Read and write : New downloaded file goes here.
  • Two same directories cannot be shared.
  • A shared directory can be a subdirectory of an existing share
  • A shared directory can contains an existing share

Symlinks : pay attention ...

Starting process

The process begin in FileManager::FileManager().

  1. Load the cache (proto buff) -> c.
  2. Give c to the cache.
  3. The cache create shared directories (SharedDirectory) -> S, sub directories (Directory) and files (File) according c.
  4. For each s in S :
    • fileUpdater->addRoot(s) (via signals).
  5. fileUpdater->start() // Start the file updater daemon (thread).
    • For each s in S :
      • scan(s) // read all directories and file from the file system.
      • restoreFromFile(s) // Give the known hashes from c to the corresponding files.

Updated by Greg Burri over 14 years ago · 5 revisions