You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by Mikhail <wm...@mail.ru> on 2017/01/23 14:31:05 UTC

Re[4]: Faceted search

Hi, Andrey.

               Thanks a lot. What are the current plans about updating the version of Lucene to the latest one? It is really straightforward, I spend about 3 hours to implement it.
               I see 2 approaches:
               1.) Implement IndexingSPI using ElasticSearch to store and get entities;
               2.) Store entities using ElasticSearch in CacheStore and query them without usage of Ignite.

               What are the advantages of the first option?

--
Best Regards,
Mikhail

>Четверг, 19 января 2017, 16:26 +03:00 от Andrey Mashenkov <an...@gmail.com>:
>
>Hi Mikhail,
>
>You can try to implement your own IndexinSPI implementation and use SPI queries, but it  seems to be non trivial task.
>Moreover Ignite already have Lucene 3.5.0 that is not supports Faceted search. So, you will need to resolve version conflicts while implementing IndexingSPI.
>
>On Thu, Jan 19, 2017 at 4:12 PM, Mikhail  < wmaster@mail.ru > wrote:
>>Hi,
>>
>>             I need to implement something like this [1]. I think, I can't implement it using just one SQL query (count the facets manually on every query is not an option). Faceted search is brilliant feature of Lucene and its family (ElasticSearch, Solr, etc). So, in order to implement it there are two options:
>>
>>1.) Use ElasticSearch (or other full text engine) as a Persistent Store.
>>2.) Use existing Ignite Lucene index for faceted search.
>>
>>I don't like the first option, because I persist my entities in database. Also I don't want to make ElasticSearch query for entities and then second Ignite query to get entities from caches. Therefore, it would be perfect if there were some mechanism in Ignite to override the "GridLuceneIndex" class and implement necessary changes. Is there some way to do it?
>>
>>[1]  http://proiot.ru/blog/posts/2016/05/15/lucene-fasetnyi-poisk/
>>
>>--
>>Best Regards,
>>Mikhail
>>
>>Wednesday, 12 January 2017, 12:19 +03:00 от vkulichenko < valentin.kulichenko@gmail.com >:
>>>
>>>Mikhail, 
>>>
>>>From what I here, you can simply use SQL for this task. Is there something in particular that doesn't work for you? 
>>>
>>>-Val
>>
>>Hi,
>>
>>              For my big data project I need to implement a catalog facet search (like in modern online shops). I need to filter by criteria (boolean, enum, range) and:
>>              1.) Show count of suitable items.
>>              2.) Hide filters that can't be applied mutually with the specified filters.
>>              3.) Show (maybe approximate) count of items for each filter, that can be specified.
>>
>>              All this I need to implement without retriving the whole list of items (opposite - it would be trivial).
>>              Could you imagine how to implement it using Ignite?
>>              I can create Persistent Store which will write to Solr or ElasticSearch, but I have already persist entities in database and use Ignite for SQL and Fulltext queries. So I would prefer not to have 2 different platforms for indexing content.
>>
>>--
>>Best Regards,
>>Mikhail Fokanov
>
>
>-- 
>С уважением,
>Машенков Андрей Владимирович
>Тел.  +7-921-932-61-82
>
>Best regards,
>Andrey V. Mashenkov
>Cerr:  +7-921-932-61-82


Re: Re[4]: Faceted search

Posted by Andrey Mashenkov <am...@gridgain.com>.
Hi Mikhail,

With 1-st approach
1. Underlying storage can be changed without rewiring its code to add
indexing support.
2. IndexSPI will updated in writeThrough(false) mode, however CacheStore
won't.

With 2-nd
1. You should bother about transaction handling (implementing
CacheStore.sessionEnd() method).
2. If you use Lucene as CacheStore in readTrough(true), you should store
whole entries in Lucene index to be able return entries via load\loadAll
methods. This will significantly increase index size.



On Mon, Jan 23, 2017 at 5:31 PM, Mikhail <wm...@mail.ru> wrote:

> Hi, Andrey.
>
>                Thanks a lot. What are the current plans about updating the
> version of Lucene to the latest one? It is really straightforward, I spend
> about 3 hours to implement it.
>                I see 2 approaches:
>                1.) Implement IndexingSPI using ElasticSearch to store and
> get entities;
>                2.) Store entities using ElasticSearch in CacheStore and
> query them without usage of Ignite.
>
>                What are the advantages of the first option?
>
> --
> Best Regards,
> Mikhail
>
> Четверг, 19 января 2017, 16:26 +03:00 от Andrey Mashenkov <
> andrey.mashenkov@gmail.com>:
>
> Hi Mikhail,
>
> You can try to implement your own IndexinSPI implementation and use SPI
> queries, but it seems to be non trivial task.
> Moreover Ignite already have Lucene 3.5.0 that is not supports Faceted
> search. So, you will need to resolve version conflicts while implementing
> IndexingSPI.
>
> On Thu, Jan 19, 2017 at 4:12 PM, Mikhail <wm...@mail.ru> wrote:
>
> Hi,
>
>              I need to implement something like this [1]. I think, I can't
> implement it using just one SQL query (count the facets manually on every
> query is not an option). Faceted search is brilliant feature of Lucene and
> its family (ElasticSearch, Solr, etc). So, in order to implement it there
> are two options:
>
> 1.) Use ElasticSearch (or other full text engine) as a Persistent Store.
> 2.) Use existing Ignite Lucene index for faceted search.
>
> I don't like the first option, because I persist my entities in database.
> Also I don't want to make ElasticSearch query for entities and then second
> Ignite query to get entities from caches. Therefore, it would be perfect if
> there were some mechanism in Ignite to override the "GridLuceneIndex" class
> and implement necessary changes. Is there some way to do it?
>
> [1] http://proiot.ru/blog/posts/2016/05/15/lucene-fasetnyi-poisk/
>
> --
> Best Regards,
> Mikhail
>
> Wednesday, 12 January 2017, 12:19 +03:00 от vkulichenko <
> valentin.kulichenko@gmail.com>:
> >
> >Mikhail,
> >
> >From what I here, you can simply use SQL for this task. Is there
> something in particular that doesn't work for you?
> >
> >-Val
>
> Hi,
>
>               For my big data project I need to implement a catalog facet
> search (like in modern online shops). I need to filter by criteria
> (boolean, enum, range) and:
>               1.) Show count of suitable items.
>               2.) Hide filters that can't be applied mutually with the
> specified filters.
>               3.) Show (maybe approximate) count of items for each filter,
> that can be specified.
>
>               All this I need to implement without retriving the whole
> list of items (opposite - it would be trivial).
>               Could you imagine how to implement it using Ignite?
>               I can create Persistent Store which will write to Solr or
> ElasticSearch, but I have already persist entities in database and use
> Ignite for SQL and Fulltext queries. So I would prefer not to have 2
> different platforms for indexing content.
>
> --
> Best Regards,
> Mikhail Fokanov
>
>
>
>
> --
> С уважением,
> Машенков Андрей Владимирович
> Тел. +7-921-932-61-82
>
> Best regards,
> Andrey V. Mashenkov
> Cerr: +7-921-932-61-82
>
>
>