Retry ES API calls that fail with 410/Gone (#56950)

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
This commit is contained in:
Rudolf Meijering 2020-02-07 10:23:27 +01:00 committed by GitHub
parent 07cb4c1e56
commit 4efd26a995
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 1 deletions

View file

@ -66,6 +66,7 @@ describe('migrationsRetryCallCluster', () => {
'RequestTimeout',
'AuthenticationException',
'AuthorizationException',
'Gone',
];
const mockLogger = loggingServiceMock.create();

View file

@ -62,7 +62,9 @@ export function migrationsRetryCallCluster(
error instanceof esErrors.ServiceUnavailable ||
error instanceof esErrors.RequestTimeout ||
error instanceof esErrors.AuthenticationException ||
error instanceof esErrors.AuthorizationException
error instanceof esErrors.AuthorizationException ||
// @ts-ignore
error instanceof esErrors.Gone
);
},
timer(delay),