By Default, Solr has several RequestHandlers that been mapped to different URLs.
you can check these settings in the solr.xml
so you can post document (xml format) to /update
or CSV document to /update/csv
Here is one quick example.
Let's say you have a simple CSV file named EE.csv
id;title
1;AndroidYou
2;David
post via CSV
run
curl "http://localhost:8080/solr/update/csv?commit=true&separator=%3b" --data-binary @ee.csv -H "Content-Type:text/plain"
then you may query
http://localhost:8080/solr/select/?q=id:2 OR id:1 to see these documents
No comments:
Post a Comment