AmazonCloudSearchCommitter
Commit documents to Amazon CloudSearch.
Notes
Commits crawled documents to an Amazon CloudSearch index. Supports field mappings, optional ID normalization for Amazon CloudSearch compatibility, and AWS credential configuration via explicit keys or environment variables.
Examples
The following example uses the minimum required settings to configure the Amazon CloudSearch Committer. This example relies on environment variables for AWS keys.
- YAML
- JSON
- XML
class: AmazonCloudSearchCommitter
serviceEndpoint: search-example-xyz.some-region.cloudsearch.amazonaws.com
{
"class": "AmazonCloudSearchCommitter",
"serviceEndpoint": "search-example-xyz.some-region.cloudsearch.amazonaws.com"
}
<committer>
<class>AmazonCloudSearchCommitter</class>
<serviceEndpoint>search-example-xyz.some-region.cloudsearch.amazonaws.com</serviceEndpoint>
</committer>
Usage
Full configuration skeleton, with every option and its default
- YAML
- JSON
- XML
class: AmazonCloudSearchCommitter
accessKey: string
acl:
flatPrefix: string
format: NATIVE
partial: REJECT
credentials:
password: string
passwordKey:
size: 0
source: KEY
value: string
username: string
fieldMappings: {}
fixBadIds: false
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: {}
secretKey: string
serviceEndpoint: string
signingRegion: string
sourceIdField: string
targetContentField: string
{
"class": "AmazonCloudSearchCommitter",
"accessKey": "string",
"acl": {
"flatPrefix": "string",
"format": "NATIVE",
"partial": "REJECT"
},
"credentials": {
"password": "string",
"passwordKey": {
"size": 0,
"source": "KEY",
"value": "string"
},
"username": "string"
},
"fieldMappings": {},
"fixBadIds": false,
"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": {}
}
],
"secretKey": "string",
"serviceEndpoint": "string",
"signingRegion": "string",
"sourceIdField": "string",
"targetContentField": "string"
}
<amazonCloudSearchCommitter>
<class>AmazonCloudSearchCommitter</class>
<accessKey>string</accessKey>
<acl>
<flatPrefix>string</flatPrefix>
<format>NATIVE</format>
<partial>REJECT</partial>
</acl>
<credentials>
<password>string</password>
<passwordKey>
<size>0</size>
<source>KEY</source>
<value>string</value>
</passwordKey>
<username>string</username>
</credentials>
<fieldMappings/>
<fixBadIds>false</fixBadIds>
<proxySettings>
<credentials>
<password>string</password>
<passwordKey/>
<username>string</username>
</credentials>
<host>
<name>string</name>
<port>0</port>
</host>
<realm>string</realm>
<scheme>string</scheme>
</proxySettings>
<queue>
<class>FsQueue</class>
<batchSize>0</batchSize>
<commitLeftoversOnInit>false</commitLeftoversOnInit>
<maxPerFolder>0</maxPerFolder>
<onCommitFailure/>
</queue>
<restrictions>
<restriction>
<fieldMatcher/>
<valueMatcher/>
</restriction>
</restrictions>
<secretKey>string</secretKey>
<serviceEndpoint>string</serviceEndpoint>
<signingRegion>string</signingRegion>
<sourceIdField>string</sourceIdField>
<targetContentField>string</targetContentField>
</amazonCloudSearchCommitter>
Properties
| Property | Type | Required | Default |
|---|---|---|---|
accessKey | string | No | - |
acl | AclCommitterConfig | No | AclCommitterConfig |
credentials | Credentials | No | Credentials |
fieldMappings | Record<string, string> | No | - |
fixBadIds | boolean | No | false |
proxySettings | ProxySettings | No | ProxySettings |
queue | CommitterQueue | No | FsQueue |
restrictions | PropertyMatcher[] | No | - |
secretKey | string | No | - |
serviceEndpoint | string | No | - |
signingRegion | string | No | - |
sourceIdField | string | No | - |
targetContentField | string | No | content |
Property Details
accessKey
Amazon CloudSearch access key. Leave blank to take it from the environment.
acl
How this committer sends the access control list (ACL) a document carries in its crawler.acl field, written by the
fetchers that read a source's permissions:
format:JSONsends the field as it is;FLATreplaces it with plain fields (below);NATIVEwrites it as the destination's own access control, for committers whose destination has one;NONEdoes not send it. When not set, the committer's default applies (NATIVEwhere available, otherwiseJSON).partial: what to do with a document whose permissions could only be read in part:REJECT(the default) orSEND.flatPrefix: the prefix of theFLATfields. Default isacl.
A document whose permissions cannot be vouched for is withheld: it is not sent, a version sent before is removed
from the destination, and the crawler tries it again on its next run. That is the case when its ACL is partial and
partial is REJECT, when its permissions could not be read at all, when the ACL is unreadable or of an unknown
version, or when NATIVE cannot express it. A withheld document is never sent as readable by everyone.
With FLAT, acl.levels names the checks a person must pass, in order, and each level has an allow field and a deny
field holding principals as kind:dir:id (or special:id):
acl.levels = share, file
acl.share.allow = group:ad:CORP:Sales
acl.file.allow = group:ad:CORP:Sales
acl.file.deny = group:ad:CORP:Interns
acl.owners = user:ad:CORP:pascal
A person may see the document if they match an allow value of every level and no deny value of any.
credentials
Credentials holding the access key as their user name and the secret key as their password, used when accessKey or secretKey is empty. Unlike secretKey, the password can be encrypted. Leave everything empty to take the keys from the environment.
fieldMappings
Mapping of source fields to target ones (index field name).
fixBadIds
Forces references to fit into an Amazon CloudSearch id field. Truncate references that are too long and append a hash code to it to keep uniqueness. It will also convert invalid characters to underscore. This approach is not 100% collision-free (uniqueness), but it should safely cover the vast majority of cases.
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.
secretKey
Amazon CloudSearch secret key. Leave blank to take it from the environment.
serviceEndpoint
Amazon CloudSearch service endpoint.
signingRegion
Amazon CloudSearch signing region.
sourceIdField
Document field name containing the value that will be stored in the Amazon CloudSearch "id" field. Default is the document reference.
targetContentField
Amazon CloudSearch field name to store the document content. Default is "content".