steadyequipment / node-firestore-backup

Google Firebase Firestore backup tool
190 stars 51 forks source link

Breaking error on large lists #48

Open BrodaNoel opened 5 years ago

BrodaNoel commented 5 years ago

Hey guys! I'm getting this error while getting a backup. I'm running this command:

firestore-backup --accountCredentials ./xxxx-xxx-firebase-xxx.json --backupPath ./backup --requestCountLimit 50

It's weird because this command always worked properly. It's backing up all the Collections, but it's failling while trying to backup the biggets Collection list (called "unsplash"). It crash even before starting backing up this big one.

Backing up Collection '/unsplash'
(node:13381) UnhandledPromiseRejectionWarning: Error: 4 DEADLINE_EXCEEDED: Deadline Exceeded
    at Object.exports.createStatusError (/Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/common.js:87:15)
    at ClientReadableStream._emitStatusIfDone (/Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/client.js:235:26)
    at ClientReadableStream._receiveStatus (/Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/client.js:213:8)
    at Object.onReceiveStatus (/Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/client_interceptors.js:1256:15)
    at InterceptingListener._callNext (/Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/client_interceptors.js:564:42)
    at InterceptingListener.onReceiveStatus (/Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/client_interceptors.js:614:8)
    at /Users/noel/.nvm/versions/node/v9.10.1/lib/node_modules/firestore-backup/node_modules/grpc/src/client_interceptors.js:1019:24
(node:13381) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:13381) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Any ideas?

BrodaNoel commented 5 years ago

This bug seems to be related to https://github.com/firebase/firebase-admin-node/issues/349

yoiang commented 5 years ago

@BrodaNoel sorry for the late reply, can you clarify the firebase-admin issue and possible routes node-firestore-backup can take?