lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ryan McKinley (JIRA)" <j...@apache.org>
Subject [jira] Updated: (SOLR-2112) Solr should support streaming response
Date Wed, 08 Sep 2010 18:23:32 GMT

     [ https://issues.apache.org/jira/browse/SOLR-2112?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Ryan McKinley updated SOLR-2112:
--------------------------------

    Attachment: SOLR-2112-StreamingSolrj.patch

Here is a patch to add streaming.  It adds this top level function to solrServer:
{code:java}
  QueryResponse queryAndStreamResponse( SolrParams params, StreamingResponseCallback callback
) 
{code}

{code:java}
public interface StreamingResponseCallback {
  public void documentRead( SolrDocument doc );
  public void documentListInfo( long numFound, long start, Float maxScore );
}
{code}

This is implemented by hacking the BinaryResponseWriter (embedded) and JavaBinCodec (http)
to send events rather then write/read documents.




> Solr should support streaming response
> --------------------------------------
>
>                 Key: SOLR-2112
>                 URL: https://issues.apache.org/jira/browse/SOLR-2112
>             Project: Solr
>          Issue Type: New Feature
>          Components: clients - java
>            Reporter: Ryan McKinley
>             Fix For: 4.0
>
>         Attachments: SOLR-2112-StreamingSolrj.patch
>
>
> The solrj API should optionally support streaming documents.
> Rather then putting all results into a SolrDocumentList, sorlj should be able to call
a callback function after each document is parsed.  This would allow someone to call query.setRows(
Integer.MAX_INT ) and get each result to the client without loading them all into memory.
> For starters, I think the important things to stream are SolrDocuments, but down the
road, this could also stream other things (consider reading all terms from the index)

-- 
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


Mime
View raw message