Skip to content

Commit

Permalink
Don't retry data view import
Browse files Browse the repository at this point in the history
  • Loading branch information
kpollich committed Oct 31, 2023
1 parent b8288fe commit 50eefde
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions x-pack/plugins/fleet/server/services/epm/kibana/assets/install.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,17 +140,16 @@ export async function installKibanaAssets(options: {
return [];
}

// Create index patterns separately with `overwrite: false` to prevent blowing away users' runtime fields
// Create index patterns separately with `overwrite: false` to prevent blowing away users' runtime fields.
// These don't get retried on conflict, because we expect that they exist once an integration has been installed.
const indexPatternSavedObjects = getIndexPatternSavedObjects() as ArchiveAsset[];
await retryImportOnConflictError(() =>
savedObjectsImporter.import({
overwrite: false,
readStream: createListStream(indexPatternSavedObjects),
createNewCopies: false,
refresh: false,
managed: true,
})
);
await savedObjectsImporter.import({
overwrite: false,
readStream: createListStream(indexPatternSavedObjects),
createNewCopies: false,
refresh: false,
managed: true,
});

const installedAssets = await installKibanaSavedObjects({
logger,
Expand Down

0 comments on commit 50eefde

Please sign in to comment.