Support for new tx handling 

Added:
* `is_completed` and `part` fields in `transactions` table,
* PRIMARY KEY changed from id to (id, part),
* migration `003`

Rest is just a merge from `migrations` branch.

**DO NOT MERGE** it yet.
Perhaps sequence_number instead of part, which is a bit ambiguous.