]> git.mxchange.org Git - quix0rs-apt-p2p.git/blobdiff - apt_dht/__init__.py
Added more TODO items and a pretty diagram to the documentation.
[quix0rs-apt-p2p.git] / apt_dht / __init__.py
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..82d30c82acff22b8c29413715c78a056e87e4dcd 100644 (file)
@@ -0,0 +1,41 @@
+
+"""The main apt-dht modules.
+
+Diagram of the interaction between the given modules::
+  
+  +---------------+    +-----------------------------------+    +-------------
+  |     AptDHT    |    |               DHT                 |    |  Internet
+  |               |--->|join                            DHT|----|--\    
+  |               |--->|loadConfig                         |    |  | Another
+  |               |--->|getValue                           |    |  | Peer
+  |               |--->|storeValue                      DHT|<---|--/
+  |               |--->|leave                              |    |
+  |               |    +-----------------------------------+    |
+  |               |    +-------------+    +----------------+    |
+  |               |    | PeerManager |    | HTTPDownloader*|    |
+  |               |--->|get          |--->|get         HTTP|----|---> Mirror
+  |               |    |             |--->|getRange        |    |
+  |               |--->|close        |--->|close       HTTP|----|--\
+  |               |    +-------------+    +----------------+    |  |
+  |               |    +-----------------------------------+    |  | Another
+  |               |    |           HTTPServer              |    |  | Peer
+  |               |--->|getHTTPFactory                 HTTP|<---|--/
+  |check_freshness|<---|                                   |    +-------------
+  |       get_resp|<---|                                   |    +-------------
+  |          /----|--->|setDirectories                 HTTP|<---|HTTP Request
+  |          |    |    +-----------------------------------+    | 
+  |          |    |    +---------------+    +--------------+    | Local Net
+  |          |    |    | CacheManager  |    | ProxyFile-   |    | (apt)
+  |          |    |--->|scanDirectories|    | Stream*      |    |
+  | setDirectories|<---|               |--->|__init__  HTTP|--->|HTTP Response
+  |               |--->|save_file      |    |              |    +-------------
+  |               |--->|save_error     |    |              |    +-------------
+  |new_cached_file|<---|               |    |          file|--->|write file
+  |               |    +---------------+    +--------------+    |
+  |               |    +---------------+    +--------------+    | Filesystem
+  |               |    | MirrorManager |    | AptPackages* |    |
+  |               |--->|updatedFile    |--->|file_updated  |--->|write file
+  |               |--->|findHash       |--->|findHash      |    |
+  +---------------+    +---------------+    +--------------+    +-------------
+
+"""