You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by Eric Pugh <ep...@opensourceconnections.com> on 2010/08/17 20:27:09 UTC

Does "maxSegments" really apply to commits?

Hi all,

I wanted to double check the docs at http://wiki.apache.org/solr/UpdateXmlMessages, does the parameter maxSegments really apply to a commit message?  

In UpdateRequest.java the code:

    if( action == ACTION.OPTIMIZE ) {
      params.set( UpdateParams.OPTIMIZE, "true" );
      params.set(UpdateParams.MAX_OPTIMIZE_SEGMENTS, maxSegments);
    }
    else if( action == ACTION.COMMIT ) {
      params.set( UpdateParams.COMMIT, "true" );
    }

seems to suggest it doesn't!  But didn't want to change the wiki without confirmation.

Eric

-----------------------------------------------------
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | http://www.opensourceconnections.com
Co-Author: Solr 1.4 Enterprise Search Server available from http://www.packtpub.com/solr-1-4-enterprise-search-server
Free/Busy: http://tinyurl.com/eric-cal









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


Re: Does "maxSegments" really apply to commits?

Posted by Lance Norskog <go...@gmail.com>.
That is correct- maxSegments controls the target number of segments
for an optimize. If you use maxSegments or above, nothing will happen.

On Tue, Aug 17, 2010 at 11:27 AM, Eric Pugh
<ep...@opensourceconnections.com> wrote:
> Hi all,
>
> I wanted to double check the docs at http://wiki.apache.org/solr/UpdateXmlMessages, does the parameter maxSegments really apply to a commit message?
>
> In UpdateRequest.java the code:
>
>    if( action == ACTION.OPTIMIZE ) {
>      params.set( UpdateParams.OPTIMIZE, "true" );
>      params.set(UpdateParams.MAX_OPTIMIZE_SEGMENTS, maxSegments);
>    }
>    else if( action == ACTION.COMMIT ) {
>      params.set( UpdateParams.COMMIT, "true" );
>    }
>
> seems to suggest it doesn't!  But didn't want to change the wiki without confirmation.
>
> Eric
>
> -----------------------------------------------------
> Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | http://www.opensourceconnections.com
> Co-Author: Solr 1.4 Enterprise Search Server available from http://www.packtpub.com/solr-1-4-enterprise-search-server
> Free/Busy: http://tinyurl.com/eric-cal
>
>
>
>
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
> For additional commands, e-mail: dev-help@lucene.apache.org
>
>



-- 
Lance Norskog
goksron@gmail.com

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