You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "Chris M. Hostetter (Jira)" <ji...@apache.org> on 2021/03/26 20:50:00 UTC

[jira] [Updated] (SOLR-15292) Warn/Fail SignatureUpdateProcessorFactory init if cloud=true & overwriteDupes=true & signatureField != id

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

Chris M. Hostetter updated SOLR-15292:
--------------------------------------
    Attachment: SOLR-15292.patch
        Status: Open  (was: Open)

90% of the patch i'm attaching is cleaning up unnecessarily duplicated updateChains across test configs.  the meat of the patch is this addition...

{noformat}
    if (getOverwriteDupes() && (null != core.getCoreDescriptor().getCloudDescriptor()) ) {
      // Not Safe, see SOLR-3473 + SOLR-15290
      if ( ! field.equals(schema.getUniqueKeyField()) ) {
        // nocommit: only log.error(..) in initial commit, then after backport to 8x change to exception
        throw new SolrException
          (ErrorCode.SERVER_ERROR,
           "Can't use overwriteDupes safely in SolrCloud when signatureField is not the uniqueKeyField: "
           + schema.getUniqueKeyField().getName());
      }
    }
{noformat}

As noted in the nocommit, this would only be what 9x looks like -- first i'd commit a similar change that would just log an ERROR in this conditional block, and after backporting to 8x would change it to throw this exception on 9x.

with this patch applied, all currently pass on 8x (and there are no failures on 9x that aren't directly due to un-related problems)

> Warn/Fail SignatureUpdateProcessorFactory init if cloud=true & overwriteDupes=true & signatureField != id
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: SOLR-15292
>                 URL: https://issues.apache.org/jira/browse/SOLR-15292
>             Project: Solr
>          Issue Type: Sub-task
>      Security Level: Public(Default Security Level. Issues are Public) 
>            Reporter: Chris M. Hostetter
>            Assignee: Chris M. Hostetter
>            Priority: Major
>         Attachments: SOLR-15292.patch
>
>
> I propose we should make SignatureUpdateProcessorFactory.inform(SolrCore) log an ERROR on 8x, and fail on 9x, if it detects:
> * This is a SolrCloud cluster
> * overwriteDupes=true
> * signatureField does not match the uniqueKey field of the collection



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org