You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Shai Erera (JIRA)" <ji...@apache.org> on 2010/09/08 14:40:32 UTC

[jira] Created: (LUCENE-2636) Create ChainingCollector

Create ChainingCollector
------------------------

                 Key: LUCENE-2636
                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
             Project: Lucene - Java
          Issue Type: New Feature
          Components: Search
            Reporter: Shai Erera
            Assignee: Shai Erera
            Priority: Minor
             Fix For: 3.1, 4.0


ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12907963#action_12907963 ] 

Shai Erera commented on LUCENE-2636:
------------------------------------

I've received some offline comments about the name - MultiCollector (the original name in our code) seems to be more aligned w/ other Lucene classes, like MultiReader/Searcher. I personally think ChainingCollector is fine as well (and describes better what this class is about), however for consistency I think I'll rename it to MultiCollector. Any objections?

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Reopened: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shai Erera reopened LUCENE-2636:
--------------------------------


Might need 1-2 iterations, so reopening.

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Resolved: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shai Erera resolved LUCENE-2636.
--------------------------------

    Resolution: Fixed

Committed revision 995373 (3x).
Committed revision 995375 (trunk).

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Updated: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shai Erera updated LUCENE-2636:
-------------------------------

    Attachment: LUCENE-2636.patch

Name changes + static wrap.

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch, LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2636) Create ChainingCollector

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12907991#action_12907991 ] 

Yonik Seeley commented on LUCENE-2636:
--------------------------------------

Heh - Solr added a MultiCollector a few weeks ago (and it does exactly the same thing).
As far as naming, I agree this isn't a chaining collector, but a branching collector (and MultiCollector is a better name).

Solr's version also has this, which simplifies building a list of collectors and then creating a single collector:
{code}
  public static Collector wrap(List<? extends Collector> collectors) {
    return collectors.size() == 1 ? collectors.get(0) : new MultiCollector(collectors);  
  }
{code}

We should consolidate these two versions of course.

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Resolved: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shai Erera resolved LUCENE-2636.
--------------------------------

    Resolution: Fixed

Committed revision 996058 (3x).
Committed revision 996060 (trunk).

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch, LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12908068#action_12908068 ] 

Shai Erera commented on LUCENE-2636:
------------------------------------

bq. Heh - Solr added a MultiCollector a few weeks ago

Nice :).

bq. ... MultiCollector is a better name

I will rename.

bq. Solr's version also has this

That makes sense. If you eventually run w/ a single Collector, no need to have MultiCollector in the middle. I'll change MC then to have a private ctor and a static create method. I would like though for the method to receive a Collector... rather than List, because I think it simplifies matters on the application's end. And create will filter out all the null ones ...

I'll post a patch soon.

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2636) Create ChainingCollector

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12908085#action_12908085 ] 

Yonik Seeley commented on LUCENE-2636:
--------------------------------------

+1 looks good!

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch, LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Updated: (LUCENE-2636) Create ChainingCollector

Posted by "Shai Erera (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2636?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shai Erera updated LUCENE-2636:
-------------------------------

    Attachment: LUCENE-2636.patch

Patch w/ ChainingCollector, a matching test and CHANGES entry.

> Create ChainingCollector
> ------------------------
>
>                 Key: LUCENE-2636
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2636
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>             Fix For: 3.1, 4.0
>
>         Attachments: LUCENE-2636.patch
>
>
> ChainingCollector allows chaining a bunch of Collectors, w/o them needing to know or care about each other, and be passed into Lucene's search API, since it is a Collector on its own. It is a convenient, yet useful, class. Will post a patch w/ it shortly.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org