Skip to content

Commit

Permalink
fix: also retry on DEADLINE_EXCEEDED
Browse files Browse the repository at this point in the history
  • Loading branch information
kirillgroshkov committed Sep 16, 2022
1 parent 993bb1a commit cdb8bc6
Show file tree
Hide file tree
Showing 4 changed files with 719 additions and 713 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"devDependencies": {
"@naturalcycles/dev-lib": "^13.0.0",
"@types/node": "^18.7.2",
"jest": "^28.1.0"
"jest": "^29.0.3"
},
"resolutions": {
"long": "^4.0.0"
Expand Down
2 changes: 1 addition & 1 deletion src/datastore.db.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import { dbQueryToDatastoreQuery } from './query.util'
// Datastore (also Firestore and other Google APIs) supports max 500 of items when saving/deleting, etc.
const MAX_ITEMS = 500

const RETRY_ON = ['GOAWAY', 'UNAVAILABLE', 'UNKNOWN', 'much contention']
const RETRY_ON = ['GOAWAY', 'UNAVAILABLE', 'UNKNOWN', 'DEADLINE_EXCEEDED', 'much contention']
// Examples of errors:
// UNKNOWN: Stream removed

Expand Down
1 change: 0 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"extends": "@naturalcycles/dev-lib/cfg/tsconfig.json",
"compilerOptions": {
"sourceMap": true,
"outDir": "./dist"
},
"include": ["src"],
Expand Down
Loading

0 comments on commit cdb8bc6

Please sign in to comment.