tmobile / sawtooth-next-directory

Home for NEXT Directory - Powered by Hyperledger Sawtooth. Chat with the team at https://chat.hyperledger.org/channel/sawtooth-next-directory/
Apache License 2.0
11 stars 7 forks source link

Backup job for packs in RethinkDB #648

Open jbobo opened 5 years ago

jbobo commented 5 years ago
User Story Backup job or packs in RethinkDB.
User Story Title Backup job for packs in RethinkDB.
T-shirt size: M
User Story "Back up pack objects (for remote rbac provider mode) for disaster recovery and to reload after upgrades requiring a redeployment of RethinkDB."
Description Write a script to be run daily to backup all pack data in RethinkDB in external storage for disaster recovery
Requirements Add a script and ephemeral microservice that runs daily and backs up all pack data from RethinkDB to be stored externally. Pack data must be retrievable and in a format that is easily/quickly reloaded into RethinkDB.
Acceptance Criteria/Tests No tests needed for this feature. Deliverable must include a new executable to backup Pack data, documentation for the output format, and a method to repeatedly run the script on a schedule.

Backup information: https://rethinkdb.com/docs/backup/

Backup table: rethinkdb dump -e rbac.packs -f packs_backup_08-27-2019.tar.gz --password-file pw.txt

Restore table: rethinkdb restore backup.tar.gz -i rbac.packs --password-file pw.txt

Questions: 1) Can't we just have a cronjob that executes the script? 2) Save in an s3 bucket?