Spencaroo
Spencaroo

Reputation: 95

Indexing to a specific core in Solr

I stress that I am a complete newbie to Solr so go easy on me if the answer is glaringly obvious.

I have created two cores on Solr as some data I want to index are unrelated, I want to keep them separate. However, when I index the data, they always go into the first core 'collection1'. I want to be able to point these files to a certain core. How do I go about this?

Many thanks

Upvotes: 1

Views: 371

Answers (1)

buddy86
buddy86

Reputation: 1454

Mention the core name while indexing your document.

Say your cores are

  1. collection1
  2. collection2

While indexing to collection1 and collection2, your solr URL should be as follows

http://'localhost':4983/solr/collection1/update?commit=true

and

http://'localhost':4983/solr/collection2/update?commit=true

Upvotes: 1

Related Questions