Skip to content

Instantly share code, notes, and snippets.

@sohangp
Last active November 5, 2019 06:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sohangp/a1c49699a43834a0f8212229daee453a to your computer and use it in GitHub Desktop.
Save sohangp/a1c49699a43834a0f8212229daee453a to your computer and use it in GitHub Desktop.
Creating Parent Data
curl -X PUT 'http://localhost:9200/family_tree/_doc/1?routing=Darren' \
-H 'content-type: application/json' \
-d '{
"firstName":"Darren",
"lastName":"Ford",
"gender":"Male",
"isAlive":false,
"relation_type":{
"name":"parent"
}
}'
curl -X PUT 'http://localhost:9200/family_tree/_doc/2?routing=Sienna' -H 'content-type: application/json' \
-d '{
"firstName":"Sienna",
"lastName":"Evans",
"gender":"Female",
"isAlive":false,
"relation_type":{
"name":"parent"
}
}'
curl -X PUT 'http://localhost:9200/family_tree/_doc/3?routing=Ryan' -H 'content-type: application/json' \
-d '{
"firstName":"Ryan",
"lastName":"Turner",
"gender":"Male",
"isAlive":false,
"relation_type":{
"name":"parent"
}
}'
@pbc3199
Copy link

pbc3199 commented Nov 5, 2019

Hi, how to convert to logstash command if the json data is from rabbitmq queue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment