You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I believe there's a bug in QueueWorker.prototype._tryToProcess regarding max retry attempts.
I ran into a "permission denied" error when someone posted to my Queue:
FIREBASE WARNING: transaction at /queues/voting/tasks/-Ke7IYBJL8obA_o9tXj6 failed: permission_denied
debug: QueueWorker 0:90f4e189-7f8b-4dec-90d5-bd4f11c8b9c8 errored while attempting to claim a new task, retrying Error: permission_denied
at Error (native)
The bug is that it got stuck in a retry loop, rather than bailing after 10 retries, and it ate up large amounts of download quota before I noticed it.
if (++retries < MAX_TRANSACTION_ATTEMPTS) {
logger.debug(self._getLogEntry('errored while attempting to ' +
'claim a new task, retrying'), error);
return setImmediate(self._tryToProcess.bind(self), deferred);
}
In most of the other functions that do something similar, they retry by calling a local function that still has retries in scope.
Steps to reproduce
I don't have a test case to reproduce, but I think the bug is apparent without it. I assume I have a bad security rule somewhere that results in the "permission denied" error.
Expected behavior
Actual behavior
The text was updated successfully, but these errors were encountered:
Version info
Firebase:
[email protected]
[email protected]
Firebase Queue:
[email protected]
Node.js:
v6.9.4
Other (e.g. operating system) (if applicable):
Test case
I believe there's a bug in
QueueWorker.prototype._tryToProcess
regarding max retry attempts.I ran into a "permission denied" error when someone posted to my Queue:
The bug is that it got stuck in a retry loop, rather than bailing after 10 retries, and it ate up large amounts of download quota before I noticed it.
I believe the bug is that the following code from https://github.com/firebase/firebase-queue/blob/master/src/lib/queue_worker.js#L484 will retry the whole
_tryToProcess
function, which resets theretries
variable.In most of the other functions that do something similar, they retry by calling a local function that still has
retries
in scope.Steps to reproduce
I don't have a test case to reproduce, but I think the bug is apparent without it. I assume I have a bad security rule somewhere that results in the "permission denied" error.
Expected behavior
Actual behavior
The text was updated successfully, but these errors were encountered: