several improvements
last_seq as a common name for what couchdb sends in changes and what river saves in index
+ bunch of other improvements
main() useful for debugging