Default Values for npm @google-cloud/bigquery Retry Options autoRetry and maxRetries
I investigated the default values for the Retry options autoRetry and maxRetries in npm @google-cloud/bigquery, so I’ll introduce them.
The default Retry settings for npm @google-cloud/bigquery appear to be: automatic retry ON, maximum retry count 3.
* @property {boolean} [autoRetry=true] Automatically retry requests if the
* response is related to rate limits or certain intermittent server errors.
* We will exponentially backoff subsequent requests by default.
* @property {number} [maxRetries=3] Maximum number of automatic retries
* attempted before returning the error.
https://github.com/googleapis/nodejs-bigquery/blob/ce2c00062b4c0b7acedd1c4d2a5dc64bd402cf1f/src/index.ts#L180-L184
Turn OFF automatic retry settings
const bigqueryClient = new BigQuery({ autoRetry: false });
Set maximum retry count to 1
const bigqueryClient = new BigQuery({ maxRetries: 1 });
That’s all from the Gemba on understanding the default values for the npm @google-cloud/bigquery Retry options autoRetry and maxRetries.