This commit is contained in:
2020-08-20 11:44:32 +02:00
parent 4715fc1814
commit 6aceefeb2f
2891 changed files with 11239 additions and 347539 deletions

7
node_modules/mongodb/lib/error.js generated vendored
View File

@@ -20,7 +20,8 @@ const GET_MORE_RESUMABLE_CODES = new Set([
150, // StaleEpoch
13388, // StaleConfig
234, // RetryChangeStream
133 // FailedToSatisfyReadPreference
133, // FailedToSatisfyReadPreference
43 // CursorNotFound
]);
function isResumableError(error, wireVersion) {
@@ -29,6 +30,10 @@ function isResumableError(error, wireVersion) {
}
if (wireVersion >= 9) {
// DRIVERS-1308: For 4.4 drivers running against 4.4 servers, drivers will add a special case to treat the CursorNotFound error code as resumable
if (error.code === 43) {
return true;
}
return error.hasErrorLabel('ResumableChangeStreamError');
}