[TASK] db: use binary instead of json
[TASK] import: implement max retry attempts