stillalex commented on PR #1504:
URL: https://github.com/apache/solr/pull/1504#issuecomment-1503929909

   Leaving this here for future reference. I think we could consider allowing 
doc updates based on the `isSubShardLeader` but this is tricky to verify, and 
well beyond my knowledge of this code. so I will remove this change from my 
current PR (this split shard test was passing with the change over a lot of 
repetitions for additions, but deletes were not applied correctly).
   
   ```
     private boolean leaderLogicWithVersionIntegrityCheck(
         boolean isReplayOrPeersync, long versionOnUpdate) {
       boolean leaderLogic = isLeader && !isReplayOrPeersync;
       if (!leaderLogic && versionOnUpdate == 0) {
         // refreshing leaderLogic status in case this is a race (see SOLR-7609)
         leaderLogic = isSubShardLeader && !isReplayOrPeersync;
         if (!leaderLogic) {
           throw new SolrException(ErrorCode.BAD_REQUEST, "missing _version_ on 
update from leader");
         }
       }
       return leaderLogic;
     }
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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

Reply via email to