[ 
https://issues.apache.org/jira/browse/SOLR-7003?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14284447#comment-14284447
 ] 

Shalin Shekhar Mangar commented on SOLR-7003:
---------------------------------------------

Hoss, I started with your suggestion but deprecating or removing the waitFlush 
method are both very trappy because of method signatures like the following:
{code}
public UpdateResponse commit(boolean waitFlush, boolean waitSearcher, boolean 
softCommit) throws SolrServerException, IOException;

public UpdateResponse commit(boolean waitFlush, boolean waitSearcher) throws 
SolrServerException, IOException;
{code}

If I move the deprecated methods to SolrServer and remove waitFlush arguments 
from SolrClient then we basically overload the commit(boolean waitSearcher, 
boolean softCommit) method in SolrServer as commit(boolean waitFlush, boolean 
waitSearcher) which is completely not what the user needs. Similarly, if we 
remove the waitFlush parameter outright from SolrClient then the user will end 
up calling a softCommit when he intended to call a hard commit with 
waitSearcher=true.

AbstractUpdateRequest has similar problems.

As a side note, we don't have a convenience method with openSearcher in 
SolrClient/SolrServer although we have one in AbstractUpdateRequest.

> Remove waitFlush boolean from SolrClients
> -----------------------------------------
>
>                 Key: SOLR-7003
>                 URL: https://issues.apache.org/jira/browse/SOLR-7003
>             Project: Solr
>          Issue Type: Task
>          Components: clients - java
>            Reporter: Shalin Shekhar Mangar
>             Fix For: 5.0, Trunk
>
>
> The waitFlush boolean for commits isn't actually used. But for some reason, 
> it was never marked deprecated in SolrServer (now called SolrClient). We 
> should nuke it.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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

Reply via email to