Skip to main content

AzureSearchCommitter

Commit documents to Microsoft Azure Search.

committer/azurecognitivesearchJavadoc: AzureSearchCommitter

Notes

Commits crawled documents to a Microsoft Azure Cognitive Search index. Supports field mappings, Base64 document key encoding, Windows authentication, and configurable handling of response and validation errors.

Examples

The following example uses the minimum required settings to configure Microsoft Azure Search Committer.

class: AzureSearchCommitter
endpoint: https://example.search.windows.net
apiKey: 1234567890ABCDEF1234567890ABCDEF
indexName: sample-index

Usage

Full configuration skeleton, with every option and its default
class: AzureSearchCommitter
apiKey: string
apiVersion: string
arrayFields: string
arrayFieldsRegex: false
disableDocKeyEncoding: false
endpoint: string
fieldMappings: {}
ignoreResponseErrors: false
ignoreValidationErrors: false
indexName: string
proxySettings:
credentials:
password: string
passwordKey: {}
username: string
host:
name: string
port: 0
realm: string
scheme: string
queue:
class: FsQueue
batchSize: 0
commitLeftoversOnInit: false
maxPerFolder: 0
onCommitFailure:
ignoreErrors: false
maxRetries: 0
retryDelay: 0
splitBatch: OFF
restrictions:
- fieldMatcher: {}
valueMatcher: {}
sourceKeyField: string
targetContentField: string
targetKeyField: string
useWindowsAuth: false

Properties

PropertyTypeRequiredDefault
apiKeystringNo-
apiVersionstringNo2020-06-30
arrayFieldsstringNo-
arrayFieldsRegexbooleanNofalse
disableDocKeyEncodingbooleanNofalse
endpointstringNo-
fieldMappingsRecord<string, string>No-
ignoreResponseErrorsbooleanNofalse
ignoreValidationErrorsbooleanNofalse
indexNamestringNo-
proxySettingsProxySettingsNoProxySettings
queueCommitterQueueNoFsQueue
restrictionsPropertyMatcher[]No-
sourceKeyFieldstringNo-
targetContentFieldstringNocontent
targetKeyFieldstringNoid
useWindowsAuthbooleanNofalse

Property Details

apiKey

Azure Search API admin key.

apiVersion

A specific Azure Search API version to use.

arrayFields

Field whose values are forcefully sent as array, even if they are single values. Unless "Use Regular Expression for Array Fields" is checked, expects a comma-separated list of field names.

arrayFieldsRegex

Use regular expression instead of comma-separated values when defining "Array Fields".

disableDocKeyEncoding

Disable Base64 encoding of the document document reference (Azure Search Document Key). Base64 is the preferred approach when your document key can contain special characters.

endpoint

Azure Search endpoint.

fieldMappings

Mapping of source fields to target ones (Azure Search fields).

ignoreResponseErrors

Log Azure Search response errors instead of throwing an exception.

ignoreValidationErrors

Do not perform validation of field names before sending a batch of documents to Azure Search.

indexName

Name of the target Azure Search index where to send documents.

proxySettings

Configures an optional HTTP proxy for outbound connections. Leave unset to connect directly.

queue

Configures the committer queue used to batch documents before sending them to the target system. Adjust queue settings to tune throughput and memory usage.

restrictions

Defines filter conditions that restrict which documents this committer processes. Documents not matching the restrictions are ignored by this committer.

sourceKeyField

Source document field name containing the value that will be stored in Azure Search target document key field. Default is the document reference.

targetContentField

Name of Azure Search document field name to store document content. Default is "content".

targetKeyField

Name of Azure Search document field where to store a document unique key identifier ("Source Key Field"). Default is "id".

useWindowsAuth

Use Windows authentication to connect.