Add 'EAI_AGAIN' as a default retry error code

The reason for adding this is it is frequently seen when sending a multitude of requests in parallel.
This commit is contained in:
jk 2016-08-01 16:33:00 -05:00 коммит произвёл Haibo Song
Родитель 541430a60a
Коммит 4b7752e565
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -130,7 +130,7 @@ RetryPolicyFilter._handle = function (self, requestOptions, next) {
// we should NOT retry within the SDK as the stream data is not valid anymore if we retry directly.
if (!returnObject.outputStreamSent && returnObject.error && azureutil.objectIsNull(returnObject.retryable) &&
((!azureutil.objectIsNull(returnObject.response) && retryInfo.retryable) ||
(returnObject.error.code === 'ETIMEDOUT' || returnObject.error.code === 'ESOCKETTIMEDOUT' || returnObject.error.code === 'ECONNRESET'))) {
(returnObject.error.code === 'ETIMEDOUT' || returnObject.error.code === 'ESOCKETTIMEDOUT' || returnObject.error.code === 'ECONNRESET' || returnObject.error.code === 'EAI_AGAIN'))) {
if (retryRequestOptions.currentLocation === Constants.StorageLocation.PRIMARY) {
lastPrimaryAttempt = returnObject.operationEndTime;