Skip to content

Commit

Permalink
Revert "[Enterprise Search] Add preferences to connectors (#150165)"
Browse files Browse the repository at this point in the history
This reverts commit f5af84f.
  • Loading branch information
navarone-feekery committed Feb 6, 2023
1 parent 8705a6a commit ead270f
Show file tree
Hide file tree
Showing 9 changed files with 0 additions and 27 deletions.
5 changes: 0 additions & 5 deletions x-pack/plugins/enterprise_search/common/types/connectors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ export interface CustomScheduling {

export type ConnectorCustomScheduling = Record<string, CustomScheduling | null>;

export interface ConnectorPreferences extends Record<string, unknown> {
extract_full_html?: boolean | null;
}

export enum ConnectorStatus {
CREATED = 'created',
NEEDS_CONFIGURATION = 'needs_configuration',
Expand Down Expand Up @@ -154,7 +150,6 @@ export interface Connector {
last_synced: string | null;
name: string;
pipeline?: IngestPipelineParams | null;
preferences: ConnectorPreferences;
scheduling: {
enabled: boolean;
interval: string; // crontab syntax
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@ export const indices: ElasticsearchIndexWithIngestion[] = [
last_sync_status: SyncStatus.COMPLETED,
last_synced: null,
name: 'connector',
preferences: { extract_full_html: false },
scheduling: {
enabled: false,
interval: '',
Expand Down Expand Up @@ -201,7 +200,6 @@ export const indices: ElasticsearchIndexWithIngestion[] = [
last_sync_status: SyncStatus.COMPLETED,
last_synced: null,
name: 'crawler',
preferences: { extract_full_html: false },
scheduling: {
enabled: false,
interval: '',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@ export const connectorIndex: ConnectorViewIndex = {
last_sync_status: SyncStatus.COMPLETED,
last_synced: null,
name: 'connector',
preferences: { extract_full_html: false },
scheduling: {
enabled: false,
interval: '',
Expand Down Expand Up @@ -215,7 +214,6 @@ export const crawlerIndex: CrawlerViewIndex = {
last_sync_status: SyncStatus.COMPLETED,
last_synced: null,
name: 'crawler',
preferences: { extract_full_html: false },
scheduling: {
enabled: false,
interval: '',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,11 +140,6 @@ describe('Setup Indices', () => {
run_ml_inference: { type: 'boolean' },
},
},
preferences: {
properties: {
extract_full_html: { type: 'boolean' },
},
},
scheduling: {
properties: {
enabled: { type: 'boolean' },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,6 @@ const connectorMappingsProperties: Record<string, MappingProperty> = {
run_ml_inference: { type: 'boolean' },
},
},
preferences: {
properties: {
extract_full_html: { type: 'boolean' },
},
},
scheduling: {
properties: {
enabled: { type: 'boolean' },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ describe('addConnector lib function', () => {
reduce_whitespace: true,
run_ml_inference: false,
},
preferences: {},
scheduling: { enabled: false, interval: '0 0 0 * * ?' },
service_type: null,
status: ConnectorStatus.CREATED,
Expand Down Expand Up @@ -340,7 +339,6 @@ describe('addConnector lib function', () => {
reduce_whitespace: true,
run_ml_inference: false,
},
preferences: {},
scheduling: { enabled: false, interval: '0 0 0 * * ?' },
service_type: null,
status: ConnectorStatus.CREATED,
Expand Down Expand Up @@ -448,7 +446,6 @@ describe('addConnector lib function', () => {
reduce_whitespace: true,
run_ml_inference: false,
},
preferences: {},
scheduling: { enabled: false, interval: '0 0 0 * * ?' },
service_type: null,
status: ConnectorStatus.CREATED,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,6 @@ export const addConnector = async (
run_ml_inference: connectorsPipelineMeta.default_run_ml_inference,
}
: null,
preferences: {},
scheduling: { enabled: false, interval: '0 0 0 * * ?' },
service_type: input.service_type || null,
status: ConnectorStatus.CREATED,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ describe('addConnector lib function', () => {
last_sync_error: null,
last_sync_status: null,
last_synced: null,
preferences: {},
scheduling: { enabled: true, interval: '1 2 3 4 5' },
service_type: null,
status: 'not connected',
Expand All @@ -68,7 +67,6 @@ describe('addConnector lib function', () => {
last_sync_error: null,
last_sync_status: null,
last_synced: null,
preferences: {},
scheduling: { enabled: true, interval: '1 2 3 4 5' },
service_type: null,
status: 'not connected',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ describe('addConnector lib function', () => {
last_sync_error: null,
last_sync_status: null,
last_synced: null,
preferences: {},
scheduling: { enabled: false, interval: '* * * * *' },
service_type: null,
status: 'not connected',
Expand Down Expand Up @@ -70,7 +69,6 @@ describe('addConnector lib function', () => {
last_sync_error: null,
last_sync_status: null,
last_synced: null,
preferences: {},
scheduling: { enabled: true, interval: '1 2 3 4 5' },
service_type: null,
status: 'not connected',
Expand Down

0 comments on commit ead270f

Please sign in to comment.