Skip to content

Instantly share code, notes, and snippets.

@sohangp

sohangp/createIndex.sh

Last active Jun 20, 2019
Embed
What would you like to do?
Create Game Of Thrones Index
curl -X PUT 'http://localhost:9200/family_tree' -H 'content-type: application/json' \
-d '{
"settings": {
"index": {
"number_of_shards": 2,
"number_of_replicas": 2
}
},
"mappings": {
"properties": {
"firstName": {
"type": "text"
},
"lastName": {
"type": "text"
},
"gender": {
"type": "text"
},
"isAlive": {
"type": "boolean"
},
"relation_type": {
"type": "join",
"eager_global_ordinals": true,
"relations": {
"parent": "child"
}
}
}
}
}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.