[Enterprise Search] Add "last_access_control_sync_error" to connector model (#159046)

This commit is contained in:
Tim Grein 2023-06-09 11:46:11 +02:00 committed by GitHub
parent 5c7753fc26
commit ab18045968
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 17 additions and 0 deletions

View file

@ -201,6 +201,7 @@ export interface Connector {
index_name: string;
is_native: boolean;
language: string | null;
last_access_control_sync_error: string | null;
last_access_control_sync_scheduled_at: string | null;
last_access_control_sync_status: SyncStatus | null;
last_incremental_sync_scheduled_at: string | null;

View file

@ -118,6 +118,7 @@ export const indices: ElasticsearchIndexWithIngestion[] = [
index_name: 'connector',
is_native: false,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,
@ -233,6 +234,7 @@ export const indices: ElasticsearchIndexWithIngestion[] = [
index_name: 'crawler',
is_native: true,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,

View file

@ -128,6 +128,7 @@ export const connectorIndex: ConnectorViewIndex = {
index_name: 'connector',
is_native: false,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,
@ -247,6 +248,7 @@ export const crawlerIndex: CrawlerViewIndex = {
index_name: 'crawler',
is_native: true,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: SyncStatus.COMPLETED,
last_incremental_sync_scheduled_at: null,

View file

@ -145,6 +145,7 @@ describe('Setup Indices', () => {
index_name: { type: 'keyword' },
is_native: { type: 'boolean' },
language: { type: 'keyword' },
last_access_control_sync_error: { type: 'keyword' },
last_access_control_sync_scheduled_at: { type: 'date' },
last_access_control_sync_status: { type: 'keyword' },
last_deleted_document_count: { type: 'long' },

View file

@ -134,6 +134,7 @@ const connectorMappingsProperties: Record<string, MappingProperty> = {
index_name: { type: 'keyword' },
is_native: { type: 'boolean' },
language: { type: 'keyword' },
last_access_control_sync_error: { type: 'keyword' },
last_access_control_sync_scheduled_at: { type: 'date' },
last_access_control_sync_status: { type: 'keyword' },
last_deleted_document_count: { type: 'long' },

View file

@ -144,6 +144,7 @@ describe('addConnector lib function', () => {
index_name: 'index_name',
is_native: false,
language: 'fr',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
@ -330,6 +331,7 @@ describe('addConnector lib function', () => {
index_name: 'index_name',
is_native: true,
language: null,
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
@ -441,6 +443,7 @@ describe('addConnector lib function', () => {
index_name: 'search-index_name',
is_native: false,
language: 'en',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,

View file

@ -40,6 +40,7 @@ describe('startSync lib function', () => {
error: null,
index_name: 'index_name',
language: null,
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_seen: null,

View file

@ -37,6 +37,7 @@ describe('addConnector lib function', () => {
custom_scheduling: {},
error: null,
index_name: 'index_name',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_seen: null,
@ -68,6 +69,7 @@ describe('addConnector lib function', () => {
custom_scheduling: {},
error: null,
index_name: 'index_name',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_seen: null,

View file

@ -90,6 +90,7 @@ describe('recreateConnectorDocument lib function', () => {
index_name: 'indexName',
is_native: false,
language: '',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,

View file

@ -85,6 +85,7 @@ describe('createConnectorDocument', () => {
index_name: 'indexName',
is_native: false,
language: 'fr',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,
@ -181,6 +182,7 @@ describe('createConnectorDocument', () => {
index_name: 'search-indexName',
is_native: false,
language: 'fr',
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,

View file

@ -114,6 +114,7 @@ export function createConnectorDocument({
index_name: indexName,
is_native: isNative,
language,
last_access_control_sync_error: null,
last_access_control_sync_scheduled_at: null,
last_access_control_sync_status: null,
last_incremental_sync_scheduled_at: null,