Skip to content

Instantly share code, notes, and snippets.

@ashald
Forked from lianyi/test.sh
Created June 12, 2017 19:06
Show Gist options
  • Save ashald/f1cfb8f789ada41c7c156fb534e64849 to your computer and use it in GitHub Desktop.
Save ashald/f1cfb8f789ada41c7c156fb534e64849 to your computer and use it in GitHub Desktop.
solr testing Transfer-Encoding: chunked
export SOLRUPDATE='http://localhost:8983/solr/testingCore/update?wt=json&commit=true'
export SOLRQUERY='http://localhost:8983/solr/testingCore/select?wt=json&q=*:*'
curl $SOLRUPDATE --data-binary '[{"id": "1"},{"id": "2"}]' -H 'Content-Type: application/json' -X POST -H "Transfer-Encoding: chunked"
#>> response {"responseHeader":{"status":0,"QTime":295}}
curl $SOLRQUERY
#>> {"responseHeader":{"status":0,"QTime":15,"params":{"q":"*:*","wt":"json"}},"response":{"numFound":2,"start":0,"maxScore":1.0,"docs":[{"id":"1","_version_":1570026155898044416},{"id":"2","_version_":1570026155878121472}]}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment