mapbox / mapbox/dynamodb-replicator

Cannot restore table backup done using dynamodb-replicator

Open
#104 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
131
Forks
46
PR merge metrics
No merged PRs in 30d

Description

I have executed command:
backup-table eu-west-1/ARTIFICIAL_APPLICANT_ID s3://some-s3

backup file is on the s3 but contains binary data not json

when I run
s3print s3://some-s3/ull/bba24099b07f53f5/0 | dyno import eu-west-1/TMP_ATSI_ARTIFICIAL_APPLICANT_ID

it says:
undefined:1

^

SyntaxError: Unexpected token in JSON at position 0
at JSON.parse ()
at Function.module.exports.deserialize (C:\Users\kamil.topolewski\AppData\Roaming\npm\node_modules\dyno\lib\serialization.js:49:18)
at Transform.Parser.parser._transform (C:\Users\kamil.topolewski\AppData\Roaming\npm\node_modules\dyno\bin\cli.js:94:25)
at Transform._read (_stream_transform.js:186:10)
at Transform._write (_stream_transform.js:174:12)
at doWrite (_stream_writable.js:387:12)
at writeOrBuffer (_stream_writable.js:373:5)
at Transform.Writable.write (_stream_writable.js:290:11)
at Stream.ondata (internal/streams/legacy.js:16:26)
at emitOne (events.js:116:13)
events.js:183
throw er; // Unhandled 'error' event
^

Error: write EPIPE
at _errnoException (util.js:1024:11)
at Socket._writeGeneric (net.js:767:25)
at Socket._write (net.js:786:8)
at doWrite (_stream_writable.js:387:12)
at writeOrBuffer (_stream_writable.js:373:5)
at Socket.Writable.write (_stream_writable.js:290:11)
at Socket.write (net.js:704:40)
at PassThrough.ondata (_stream_readable.js:639:20)
at emitOne (events.js:116:13)
at PassThrough.emit (events.js:211:7)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the backup with `backup-table eu-west-1/ARTIFICIAL_APPLICANT_ID s3://some-s3`, then inspect the S3 object produced at the shown path and the `s3print | dyno import` pipeline. Determine why the backup contains binary data while `dyno import` expects JSON; done means a backup can be restored successfully through the documented commands.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, javascript, node.js
Domain
cloud, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.