AWS Tips
Elasticsearch
Terms
Domain - concept like a database
Index - concept like a table
Json data - concept like a row in a table
Add Data to Elastic via API:
Post operation: send json data to the following url pattern
https://<domain><unique identifier aws generates>/<index>/_doc
Response operation:
{ "_index": "index name"
"_type": "_doc"
"_id": "ABCD12345EFGHIxlkmn"
"_version": 1,
"result": "created"
"_shards": {
"total" : 2,
"successful": 1,
"failed": 0
},
"_seq_no": 0,
"_primary _term": 1
}
Get Data from elastic via API:
Get operation: send the "_id" value to the following url pattern
https://<domain><unique identifier aws generates>/<index>/_doc/<_id>
Response Json:
{ "_index": "index name"
"_type": "_doc"
"_id": "ABCD12345EFGHIxlkmn"
"_version": 1,
"_seq_no": 0,
"_primary _term": 1,
"found": true
"_source": {
<json data that was sent in the post operation
}
}