You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by BenDede <we...@gmail.com> on 2008/12/09 16:36:06 UTC

Index with fields stored or not and good use of RESTful

Hello,

I think I have not all understand with Solr... :(

I have got datas in a database and I use DataImportHandler to index it, but
I have a question for the next. What are the best solution?

1. Have an light index, which not stored data and do requests in the
database to get it.
Or 
2. Have directly an index which stored the datas needs. 


The case two is the most easy but i think not the good solution.

For the case one, how do you do that? 
1. After the send of the result by the REST request: get IDs, requests
database, ...
Or 
2. Before the send of the result by the REST request with a modification of
Solr's sources?

Here, I think, the case two is the best solution too. Exists-it already
something for doing that?


My first idea was to create an webservice REST in PHP, which be an
intermediary to the webservice REST of Solr, which doing requests to the
database with IDs from Solr's index. But I think that is heavy. No?


Thanks. 
And sorry for my english. I'm french, :/ 
-- 
View this message in context: http://www.nabble.com/Index-with-fields-stored-or-not-and-good-use-of-RESTful-tp20916994p20916994.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Index with fields stored or not and good use of RESTful

Posted by Yonik Seeley <yo...@apache.org>.
On Tue, Dec 9, 2008 at 10:36 AM, BenDede <we...@gmail.com> wrote:
>
> Hello,
>
> I think I have not all understand with Solr... :(
>
> I have got datas in a database and I use DataImportHandler to index it, but
> I have a question for the next. What are the best solution?
>
> 1. Have an light index, which not stored data and do requests in the
> database to get it.
> Or
> 2. Have directly an index which stored the datas needs.

If #2 works (just store the data you need to retrieve in Solr) then use it.
It makes for simpler front-ends, allows Solr to do things like
highlighting for you, keeps the content associated with ids in sync,
and potentially removes a point-of-failure on the search-side (if all
your webapp needs to query is solr, then the db can go down for short
periods of time w/o affecting service).

-Yonik

> The case two is the most easy but i think not the good solution.
>
> For the case one, how do you do that?
> 1. After the send of the result by the REST request: get IDs, requests
> database, ...
> Or
> 2. Before the send of the result by the REST request with a modification of
> Solr's sources?
>
> Here, I think, the case two is the best solution too. Exists-it already
> something for doing that?
>
>
> My first idea was to create an webservice REST in PHP, which be an
> intermediary to the webservice REST of Solr, which doing requests to the
> database with IDs from Solr's index. But I think that is heavy. No?
>
>
> Thanks.
> And sorry for my english. I'm french, :/
> --
> View this message in context: http://www.nabble.com/Index-with-fields-stored-or-not-and-good-use-of-RESTful-tp20916994p20916994.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>