commit 2f10aeec5840fabaf87a7e263103e647839c89ef Merge: aaa668ba 5d0feb73 Author: Damian Johnson atagar@torproject.org Date: Fri Aug 25 13:28:31 2017 -0700
Sqlite cache for manual information
Moving from a stem.util.conf to sqlite cache for manual information. This provides two benefits...
* Faster loading. On my laptop (which has an ssd) this is 8x faster, from 16ms to 2ms.
* Random access reads. A new stem.manual.database() function provides a cursor into our cache, so callers can get specific information without reading the whole thing.
Hope is that this will allow us to drop Nyx's memory usage a bit by not keeping a bunch of unnecessary content in memory. Also practice so I could try the sqlite3 module, which nyx will be using more of shortly.
docs/change_log.rst | 2 + setup.py | 2 +- stem/cached_tor_manual.cfg | 1886 ----------------------------------------- stem/cached_tor_manual.sqlite | Bin 0 -> 202752 bytes stem/manual.py | 111 ++- stem/settings.cfg | 2 + test/unit/manual.py | 21 +- 7 files changed, 133 insertions(+), 1891 deletions(-)
tor-commits@lists.torproject.org