Re: Few Queries regarding indexes in Solr

2009-06-18 Thread Michael Ludwig

Otis Gospodnetic schrieb:

[...] nothing prevents the indexing client from sending the same doc
to multiple shards.  In some scenarios that's exactly what you want
to do.

What kind of scenario would that be?


One scenario is making use of small and large core to provide near
real-time search - you index to both - to smaller so you can
flip/drop/purge+reopen it frequently and quickly, the large one to
persist.  You search across both of them and remove dupes.


This makes sense. Thanks for taking the time to answer this.


Q: What is the most annoying thing in e-mail?


A: it never stops!


Imagine it did one day!

Michael Ludwig


Re: Few Queries regarding indexes in Solr

2009-06-17 Thread Michael Ludwig

Otis Gospodnetic schrieb:

Regarding that 3rd answer below:


Putting it back in context (where it belongs :-) :


My (very limited) understanding of shards is that you repartition
your documents among shards and send each document to only one
shard. (Not sure this is correct.)



Yes, that's what most people do, though nothing prevents the indexing
client from sending the same doc to multiple shards.  In some
scenarios that's exactly what you want to do.


What kind of scenario would that be?

Michael Ludwig

--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?


Re: Few Queries regarding indexes in Solr

2009-06-17 Thread Otis Gospodnetic

Hi Michael,

- Original Message 
 From: Michael Ludwig m...@as-guides.com
 To: solr-user@lucene.apache.org
 Sent: Wednesday, June 17, 2009 8:34:10 AM
 Subject: Re: Few Queries regarding indexes in Solr
 
 Otis Gospodnetic schrieb:
  Regarding that 3rd answer below:
 
 Putting it back in context (where it belongs :-) :
 
  My (very limited) understanding of shards is that you repartition
  your documents among shards and send each document to only one
  shard. (Not sure this is correct.)
 
  Yes, that's what most people do, though nothing prevents the indexing
  client from sending the same doc to multiple shards.  In some
  scenarios that's exactly what you want to do.
 
 What kind of scenario would that be?

One scenario is making use of small and large core to provide near real-time 
search - you index to both - to smaller so you can flip/drop/purge+reopen it 
frequently and quickly, the large one to persist.  You search across both of 
them and remove dupes.

 -- A: Because it messes up the order in which people normally read text.
 Q: Why is top-posting such a bad thing?
 A: Top-posting.
 Q: What is the most annoying thing in e-mail?

A: it never stops!

Otis


Few Queries regarding indexes in Solr

2009-06-16 Thread Rakhi Khatwani
Hi,
  1. Is it possible to query from another index folder (say index1) in
solr?
  2. Is it possible to query 2 indexes(folders index1 and index2) stored
in the same machine using the same port on a single solr instance?
  3. consider a case:
   i have indexes in 2 shards, and i merge the indexes (present in 2
shards) onto the 3rd shard
   now i add more documents into shard1 and delete some documents
from shard 2 and update the indexes.
   is it possible to send the differences only into shard 3 and then
merge it at shard 3?

Regards,
Raakhi


Re: Few Queries regarding indexes in Solr

2009-06-16 Thread Otis Gospodnetic

Hello,

 
Answers inlined.


- Original Message 

   1. Is it possible to query from another index folder (say index1) in
 solr?

You don't really query *from* an index, so I'm not sure what exactly you mean.  
However, you can query Solr remotely, if that's what you mean, for example 
using SolrJ if your application is written in Java.

   2. Is it possible to query 2 indexes(folders index1 and index2) stored
 in the same machine using the same port on a single solr instance?


Yes, please look for DistributedSearch on the Wiki.

   3. consider a case:
i have indexes in 2 shards, and i merge the indexes (present in 2
 shards) onto the 3rd shard
now i add more documents into shard1 and delete some documents
 from shard 2 and update the indexes.
is it possible to send the differences only into shard 3 and then
 merge it at shard 3?


If I understood you correctly, then no, sending only the newly added/deleted 
documents in 2 indices to the 3rd index after the fact is not doable.

Otis
--
Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch



Re: Few Queries regarding indexes in Solr

2009-06-16 Thread Michael Ludwig

Rakhi Khatwani schrieb:


1. Is it possible to query from another index folder (say
index1) in solr?


I think you're looking for the multi-core feature.

http://wiki.apache.org/solr/MultipleIndexes
http://wiki.apache.org/solr/CoreAdmin


2. Is it possible to query 2 indexes(folders index1 and index2)
stored in the same machine using the same port on a single solr
instance?


Sounds like multi-core.


3. consider a case: i have indexes in 2 shards, and i merge the
indexes (present in 2 shards) onto the 3rd shard now i add more
documents into shard1 and delete some documents from shard 2 and
update the indexes. is it possible to send the differences only
into shard 3 and then merge it at shard 3?


My (very limited) understanding of shards is that you repartition
your documents among shards and send each document to only one
shard. (Not sure this is correct.)

Michael Ludwig


Re: Few Queries regarding indexes in Solr

2009-06-16 Thread Otis Gospodnetic

Regarding that 3rd answer below:
Yes, that's what most people do, though nothing prevents the indexing client 
from sending the same doc to multiple shards.  In some scenarios that's exactly 
what you want to do.

 Otis
--
Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch



- Original Message 
 From: Michael Ludwig m...@as-guides.com
 To: solr-user@lucene.apache.org
 Sent: Tuesday, June 16, 2009 8:36:25 AM
 Subject: Re: Few Queries regarding indexes in Solr
 
 Rakhi Khatwani schrieb:
 
  1. Is it possible to query from another index folder (say
  index1) in solr?
 
 I think you're looking for the multi-core feature.
 
 http://wiki.apache.org/solr/MultipleIndexes
 http://wiki.apache.org/solr/CoreAdmin
 
  2. Is it possible to query 2 indexes(folders index1 and index2)
  stored in the same machine using the same port on a single solr
  instance?
 
 Sounds like multi-core.
 
  3. consider a case: i have indexes in 2 shards, and i merge the
  indexes (present in 2 shards) onto the 3rd shard now i add more
  documents into shard1 and delete some documents from shard 2 and
  update the indexes. is it possible to send the differences only
  into shard 3 and then merge it at shard 3?
 
 My (very limited) understanding of shards is that you repartition
 your documents among shards and send each document to only one
 shard. (Not sure this is correct.)
 
 Michael Ludwig