Class SearchIndexerDataSources
SearchIndexerDataSourceConnections
.-
Method Summary
Modifier and TypeMethodDescriptioncreateFromAzureBlobStorage
(String dataSourceName, String storageConnectionString, String containerName) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Blob container.createFromAzureBlobStorage
(String dataSourceName, String storageConnectionString, String containerName, String pathPrefix, String description, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Blob container.createFromAzureSql
(String dataSourceName, String sqlConnectionString, String tableOrViewName) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure SQL database.createFromAzureSql
(String dataSourceName, String sqlConnectionString, String tableOrViewName, String description, DataChangeDetectionPolicy changeDetectionPolicy, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure SQL database.createFromAzureTableStorage
(String dataSourceName, String storageConnectionString, String tableName) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Table.createFromAzureTableStorage
(String dataSourceName, String storageConnectionString, String tableName, String query, String description, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Table.createFromCosmos
(String dataSourceName, String cosmosConnectionString, String collectionName) Creates a newSearchIndexerDataSourceConnection
to connect to a Cosmos database with change detection set to true.createFromCosmos
(String dataSourceName, String cosmosConnectionString, String collectionName, Boolean useChangeDetection) Creates a newSearchIndexerDataSourceConnection
to connect to a Cosmos database.createFromCosmos
(String dataSourceName, String cosmosConnectionString, String collectionName, String query, Boolean useChangeDetection, String description, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to a Cosmos database.
-
Method Details
-
createFromAzureSql
public static SearchIndexerDataSourceConnection createFromAzureSql(String dataSourceName, String sqlConnectionString, String tableOrViewName, String description, DataChangeDetectionPolicy changeDetectionPolicy, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure SQL database.- Parameters:
dataSourceName
- The name of the data source.sqlConnectionString
- The connection string for the Azure SQL database.tableOrViewName
- The name of the table or view from which to read rows.description
- Optional. Description of the data source.changeDetectionPolicy
- The change detection policy for the data source. Note that only high watermark change detection is allowed for Azure SQL when deletion detection is enabled.deletionDetectionPolicy
- Optional. The data deletion detection policy for the data source.- Returns:
- A new Azure SQL
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,sqlConnectionString
, ortableOrViewName
is null or empty.
-
createFromAzureSql
public static SearchIndexerDataSourceConnection createFromAzureSql(String dataSourceName, String sqlConnectionString, String tableOrViewName) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure SQL database.- Parameters:
dataSourceName
- The name of the data source.sqlConnectionString
- The connection string for the Azure SQL database.tableOrViewName
- The name of the table or view from which to read rows.- Returns:
- A new Azure SQL
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,sqlConnectionString
, ortableOrViewName
is null or empty.
-
createFromAzureBlobStorage
public static SearchIndexerDataSourceConnection createFromAzureBlobStorage(String dataSourceName, String storageConnectionString, String containerName, String pathPrefix, String description, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Blob container.- Parameters:
dataSourceName
- The name of the data source.storageConnectionString
- The connection string for the Azure Storage account. The Storage connection string must use this format:"DefaultEndpointsProtocol=https;AccountName=[your storage account];AccountKey=[your account key]:
Note: The connection string must use HTTPS.
containerName
- The name of the container from which to read blobs.pathPrefix
- Optional. Limits the data source to only include blobs starting with the specified prefix, this is useful when blobs are organized into "virtual folders".description
- Optional. Description of the data sourcedeletionDetectionPolicy
- Optional. The data deletion detection policy for the data source- Returns:
- A new Azure Blob
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,containerName
orstorageConnectionString
is null or empty.
-
createFromAzureBlobStorage
public static SearchIndexerDataSourceConnection createFromAzureBlobStorage(String dataSourceName, String storageConnectionString, String containerName) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Blob container.- Parameters:
dataSourceName
- The name of the data source.storageConnectionString
- The connection string for the Azure Storage account. The Storage connection string must use this format:"DefaultEndpointsProtocol=https;AccountName=[your storage account];AccountKey=[your account key]:
Note: The connection string must use HTTPS.
containerName
- The name of the container from which to read blobs.- Returns:
- A new Azure Blob
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,containerName
orstorageConnectionString
is null or empty.
-
createFromAzureTableStorage
public static SearchIndexerDataSourceConnection createFromAzureTableStorage(String dataSourceName, String storageConnectionString, String tableName, String query, String description, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Table.- Parameters:
dataSourceName
- The name of the data source.storageConnectionString
- The connection string for the Azure Storage account. The Storage connection string must use this format:"DefaultEndpointsProtocol=https;AccountName=[your storage account];AccountKey=[your account key]:
Note: The connection string must use HTTPS.
tableName
- The name of the Azure table from which to read rows.query
- Optional. A query that is applied to the table when reading rows.description
- Optional. Description of the data sourcedeletionDetectionPolicy
- Optional. The data deletion detection policy for the data source.- Returns:
- A new Azure Table
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,tableName
, orstorageConnectionString
is null or empty.
-
createFromAzureTableStorage
public static SearchIndexerDataSourceConnection createFromAzureTableStorage(String dataSourceName, String storageConnectionString, String tableName) Creates a newSearchIndexerDataSourceConnection
to connect to an Azure Table.- Parameters:
dataSourceName
- The name of the data source.storageConnectionString
- The connection string for the Azure Storage account. The Storage connection string must use this format:"DefaultEndpointsProtocol=https;AccountName=[your storage account];AccountKey=[your account key]:
Note: The connection string must use HTTPS.
tableName
- The name of the Azure table from which to read rows.- Returns:
- A new Azure Table
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,tableName
, orstorageConnectionString
is null or empty.
-
createFromCosmos
public static SearchIndexerDataSourceConnection createFromCosmos(String dataSourceName, String cosmosConnectionString, String collectionName, String query, Boolean useChangeDetection, String description, DataDeletionDetectionPolicy deletionDetectionPolicy) Creates a newSearchIndexerDataSourceConnection
to connect to a Cosmos database.- Parameters:
dataSourceName
- The name of the data source.cosmosConnectionString
- The connection string for the Cosmos database. It must follow this format:AccountName|AccountEndpoint=[your account name or endpoint]; AccountKey=[your account key];Database=[your database name]"
collectionName
- The name of the collection from which to read documents.query
- Optional. A query that is applied to the collection when reading documents.useChangeDetection
- Optional. Indicates whether to use change detection when indexing. Default is true.description
- Optional. Description of the data sourcedeletionDetectionPolicy
- Optional. The data deletion detection policy for the data source.- Returns:
- A new Cosmos
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,collectionName
, orcosmosConnectionString
is null or empty.
-
createFromCosmos
public static SearchIndexerDataSourceConnection createFromCosmos(String dataSourceName, String cosmosConnectionString, String collectionName, Boolean useChangeDetection) Creates a newSearchIndexerDataSourceConnection
to connect to a Cosmos database.- Parameters:
dataSourceName
- The name of the data source.cosmosConnectionString
- The connection string for the Cosmos database. It must follow this format:AccountName|AccountEndpoint=[your account name or endpoint]; AccountKey=[your account key];Database=[your database name]"
collectionName
- The name of the collection from which to read documentsuseChangeDetection
- Optional. Indicates whether to use change detection when indexing. Default is true.- Returns:
- A new Cosmos
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,collectionName
, orcosmosConnectionString
is null or empty.
-
createFromCosmos
public static SearchIndexerDataSourceConnection createFromCosmos(String dataSourceName, String cosmosConnectionString, String collectionName) Creates a newSearchIndexerDataSourceConnection
to connect to a Cosmos database with change detection set to true.- Parameters:
dataSourceName
- The name of the data source.cosmosConnectionString
- The connection string for the Cosmos database. It must follow this format:AccountName|AccountEndpoint=[your account name or endpoint]; AccountKey=[your account key];Database=[your database name]"
collectionName
- The name of the collection from which to read documents- Returns:
- A new Cosmos
SearchIndexerDataSourceConnection
instance. - Throws:
IllegalArgumentException
- IfdataSourceName
,collectionName
, orcosmosConnectionString
is null or empty.
-