djs22
djs22

Reputation: 1156

SOLR Index a remote file

Does anyone know how to index a remote file using SOLR? I've tried the following

curl http://localhost:8983/solr/update/extract?literal.id=rem1&uprefix=attr_&fmap.content=body&commit=true" -F stream.url=http://fakesite.com

with no luck.

The local host equivalent

curl http://localhost:8983/solr/update/extract?literal.id=rem1&uprefix=attr_&fmap.content=body&commit=true" -F "stream.url=http://duke.edu/web/aepi/"

works fine.

Thanks! djs22

Upvotes: 3

Views: 3525

Answers (1)

Mauricio Scheffer
Mauricio Scheffer

Reputation: 99720

For security reasons, remote streaming is disabled by default. From the Solr wiki:

If streaming is enabled, you need to make sure Solr is as secure as it needs to be. When streaming is enabled, the parameters "stream.url" will go to a remote site and download the content. Likewise, "stream.file" will read a file on disk.

Streaming is disabled by default and is configured from solrconfig.xml

 <requestParsers enableRemoteStreaming="false" ... />

Upvotes: 4

Related Questions