Skip to content

Commit

Permalink
[Search] Fix native connectors not configuring correctly (#168858)
Browse files Browse the repository at this point in the history
## Summary

This fixes an issue with native connectors not being set to configured
after being configured.
  • Loading branch information
sphilipse authored Oct 13, 2023
1 parent 58df0aa commit ddcc528
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export function createConnectorDocument({
incremental: { enabled: false, interval: '0 0 0 * * ?' },
},
service_type: serviceType || null,
status: ConnectorStatus.CREATED,
status: isNative ? ConnectorStatus.NEEDS_CONFIGURATION : ConnectorStatus.CREATED,
sync_now: false,
};
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ export const updateConnectorConfiguration = async (
const connector = connectorResult?.value;
if (connector) {
const status =
connector.status === ConnectorStatus.NEEDS_CONFIGURATION
connector.status === ConnectorStatus.NEEDS_CONFIGURATION ||
connector.status === ConnectorStatus.CREATED
? ConnectorStatus.CONFIGURED
: connector.status;
const updatedConfig = Object.keys(connector.configuration)
Expand Down

0 comments on commit ddcc528

Please sign in to comment.