Add RCF to pick user fetching strategy (#161546)

## Summary

Part of https://github.com/elastic/connectors-python/issues/1204

This adds a configuration for the sharepoint online native connector to
allow it to choose between approaches when fetching users for DLS.


### Checklist


- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)

### For maintainers

- [ ] This was checked for breaking API changes and was [labeled
appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
This commit is contained in:
Sean Story 2023-07-10 17:06:09 -05:00 committed by GitHub
parent 4ae5e1757e
commit fd2ecdfb27
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1652,6 +1652,32 @@ export const NATIVE_CONNECTOR_DEFINITIONS: Record<string, NativeConnector | unde
validations: [],
value: false,
},
fetch_users_by_site: {
default_value: false,
depends_on: [{ field: 'use_document_level_security', value: true }],
display: DisplayType.TOGGLE,
label: i18n.translate(
'xpack.enterpriseSearch.nativeConnectors.sharepoint_online.configuration.fetchUsersBySiteLabel',
{
defaultMessage: 'Discover users by site membership',
}
),
options: [],
order: 8,
required: true,
sensitive: false,
tooltip: i18n.translate(
'xpack.enterpriseSearch.nativeConnectors.sharepoint_online.configuration.fetchUsersBySiteTooltip',
{
defaultMessage:
'When syncing only a small subset of sites, it can be more efficient to only fetch users who have access to those sites. This becomes increasingly inefficient the more sites (and the more users) concerned.',
}
),
type: FieldType.BOOLEAN,
ui_restrictions: [],
validations: [],
value: false,
},
},
features: {
[FeatureName.SYNC_RULES]: {