curl command for bin/post any file curl command for bin/post any file curl curl

curl command for bin/post any file


Eventually, somewhere in the Ocean of forums, threads and blogs I found a solution. The right way to index a plain (unstructured) text file is this one:

$ curl 'http://127.0.0.1:8983:/solr/collection1/update/extract/?literal.id=any_document_id_you_like&commit=true' -F 'myfile=@path_to_the_file_you_want_to_index'

That works as expected. I wish there was something about this way of doing things in the documentation.