adds support for a portable db import/export format (closes: #1521112)
the db-dump and db-restore cwctl commands are enhanced with a --format option
(defaults to 'native'). If the format is 'portable', then the system database
dump / restore is performed using pure SQL queries and the storage uses picked
Python objects in a zip archive.
add a new method iter_process_result which does the same as proces_result but is a generator (closes #1625374)
process_result is reimplemented using the new method, and the two helper
methods are turned into generators.
These generators use cursor.fetchmany instead of cursor.fetchall after setting
cursor.arraysize to 100. This means that the whole result set should never
loaded in memory when using the iter_process_result method. This is used in the
"portable" database dump implementation when we typically to 'SELECT * FROM
table', but could probably be used too in other parts of cubicweb.