Setting the file. One moment.
Chapter 45 · Amazon Opensearch Service
Subchapter 45.52
assets/solr-index-template-skeleton.mdMarkdown4 KBView on GitHub
You MUST fill in the placeholders during Step 3 (Translate Schema). You MUST emit one properties entry per Solr field. You MUST map the Solr uniqueKey to OpenSearch _id and set explicitly on every index request. You MUST NOT rely on auto-generated IDs because doing so breaks idempotent re-indexing and dedup-by-fingerprint workflows.
_id{
"index_patterns": ["<index-name>-*"],
"template": {
"settings": {
"number_of_shards": 1,
"number_of_replicas": 1,
"refresh_interval": "30s",
"analysis": {
"analyzer": {
"<custom_analyzer>": {
"type": "custom",
"tokenizer": "<tokenizer>",
"filter": ["lowercase", "<filter>"]
}
},
"filter": {
"<filter>": {
"type": "synonym_graph",
"synonyms_path": "analyzers/<file>.txt"
}
}
}
},
"mappings": {
"dynamic_templates": [
{
"strings_as_keyword": {
"match_mapping_type": "string",
"mapping": { "type": "keyword" }
}
}
],
"properties": {
"<solr_uniqueKey>": { "type": "keyword" },
"<text_field>": {
"type": "text",
"analyzer": "<custom_analyzer>",
"fields": { "raw": { "type": "keyword", "ignore_above": 256 } }
},
"<int_field>": { "type": "integer" },
"<long_field>": { "type": "long" },
"<date_field>": { "type": "date", "format": "epoch_millis||strict_date_optional_time" },
"<geo_field>": { "type": "geo_point" }
}
}
}
}index_patterns matches the target index name.number_of_shards / number_of_replicas come from Step 5 (Estimate Sizing).properties entry. You MUST NOT rely on dynamic mapping for production fields because dynamic mapping causes type conflicts.uniqueKey is mapped to a keyword field AND set as _id on every index request."format" matches the on-the-wire encoding — strict_date_optional_time for ISO-8601 strings (default), epoch_millis for long integers, or both (strict_date_optional_time||epoch_millis) per solr-transformation-rules (opens in a new tab)."lat,lon") are converted to geo_point objects._version_, _root_, _nest_path_) are stripped before indexing.product.id) are renamed to use underscores.schema.xml are replicated as analysis.analyzer blocks; filter order preserved.EncryptionAtRestOptions); node-to-node encryption (NodeToNodeEncryptionOptions); HTTPS enforced (EnforceHTTPS: true, TLSSecurityPolicy: Policy-Min-TLS-1-2-2019-07); fine-grained access control (FGAC) with IAM/SAML/OIDC authentication; access policy scoped by principal and source ARN/account. You MUST NOT use 0.0.0.0/0 because it exposes the cluster to the entire internet.CustomEndpoint.CertificateArn) for automated rotation. You MUST NOT use a self-managed certificate because expiry will silently break TLS in production.You MUST embed the filled-in template in section 2. Schema Mapping of report-template. You MUST cite the source schema.xml line range (or Schema API field name) for each non-trivial mapping decision in the table.