5

Is there a way to write external file (containing external file field) for Solr via some API?

I tried to find into Solr docs but unable to find anything that help!!

Here is more details as requested.

I am working on a project where I have few details which are updated very frequently stored in external file, exactly same as this question: How can I read and write the external file field in solr?

We use the field for some function query and sorting purposes while performing search queries into Solr. This works fine.

However, this file needs to be on Solr Data directory. So it resides where Solr is installed. Now consider my case, where my main application is on a different Windows Server, communicating to the Solr via SolrNet. But my Solr instance is on a remote machine dedicated to Solr.

My problem is:

  1. How to transfer / write to this file to Solr Server from my asp.net application hosted on windows machine which is physically a separate machine.
  2. Is there any way / API built into Solr that allows to create / update this file from one of its API?

Any other suggestions on the same are always welcome.

cheffe
  • 9,345
  • 2
  • 46
  • 57
Krunal
  • 2,967
  • 8
  • 45
  • 101
  • can you put in more details what you want to achieve? – Sumeet Sharma Nov 09 '15 at 05:35
  • http://stackoverflow.com/questions/13722245/how-can-i-read-and-write-the-external-file-field-in-solr – Sumeet Sharma Nov 09 '15 at 05:39
  • @SumeetSharma Thanks for looking at this, just added more details. – Krunal Nov 10 '15 at 06:00
  • What OS is your solr running on? I assume some sort of Linux? – cheffe Apr 17 '19 at 06:12
  • @mlissner Any reason why you can't use updatable DocValues instead? i.e. [in-place updates](https://lucene.apache.org/solr/guide/6_6/updating-parts-of-documents.html#UpdatingPartsofDocuments-In-PlaceUpdates) – MatsLindh Apr 17 '19 at 06:44
  • @MatsLindh, this is a external boosting file that has pagerank scores for millions of items. I guess we *could* update millions of items in Solr whenever we recalculate the pagerank scores, but man, it's a lot easier to just use a flat file. – mlissner Apr 17 '19 at 16:29
  • 1
    @mlissner Sure, that's why I'm asking - if you wanted an API to change a single value every now and then, in-place DocValues would work fine - if you need to change a million rows often, swapping the file makes more sense. – MatsLindh Apr 17 '19 at 19:30
  • @MatsLindh Yes, I agree with that. We are doing it exactly same way. – Krunal Apr 18 '19 at 07:29

0 Answers0