Merge lp:~jderose/microfiber/db-dump into lp:microfiber
Proposed by
Jason Gerard DeRose
Status: | Merged |
---|---|
Merged at revision: | 133 |
Proposed branch: | lp:~jderose/microfiber/db-dump |
Merge into: | lp:microfiber |
Diff against target: |
368 lines (+260/-26) 3 files modified
doc/microfiber.rst (+29/-1) microfiber.py (+107/-25) test_microfiber.py (+124/-0) |
To merge this branch: | bzr merge lp:~jderose/microfiber/db-dump |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
microfiber dev | Pending | ||
Review via email:
|
Description of the change
Use the revised Database.dump() method like this:
>>> db.dump('foo.json')
Or gzip-compress the dump:
>>> db.dump(
Like before, doc['_rev'] is deleted before dumping to the file. However, the attachments kwarg was removed, and now we only dump *without* the attachments. Even the stub doc['_attachments'] gets deleted when present. We'll probably add some more flexibility here later, but for now it suits the needs of Novacut and Dmedia.
Also, two big performance improvements were made:
1) We request docs 50 at a time (roughly 4x improvement)
2) We make CouchDB requests in a separate thread (roughly 2x improvement after above)
To post a comment you must log in.
Approved.