You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@bookkeeper.apache.org by GitBox <gi...@apache.org> on 2022/06/27 08:40:52 UTC

[GitHub] [bookkeeper] horizonzy commented on pull request #3359: Feature: auto recover support repaired not adhering placement ledger

horizonzy commented on PR #3359:
URL: https://github.com/apache/bookkeeper/pull/3359#issuecomment-1167058078

   For this case, we already support detect these ledger which ensemble is not adhering placement policy at now.
   In Auditor, if user config `auditorPeriodicPlacementPolicyCheckInterval`, it will start a scheduled task to trigger `placementPolicyCheck`, In `placementPolicyCheck`, it will record the count of ledger fragment which not adhering placement policy.
   https://github.com/apache/bookkeeper/blob/677ccec3eb84f5be1b3556537871e14eb5e8359c/bookkeeper-server/src/main/java/org/apache/bookkeeper/replication/Auditor.java#L1378
   
   But it only record it to stat, not recover data to  make ensemble to adhere placement policy.
   
   So we can add a config `repairedPlacementPolicyNotAdheringBookieEnabled` to control is to repaired the data to adhere placement policy.
   
   **In Auditor**
   It will mark ledgerId to unnder replication managed if the ensemble is not adhering placement policy.
   
   **In ReplicationWorker**
   It will move data from old bookie to new bookie which network location is different to adhere placement policy. If there is not bookie with different network location, do nothing.
   
   _Attention_
   _In ReplicationWoker, it just poll under replicated ledger then process it. So when get an under replicated ledger, we should check two case. 1) Is the ledger fragments loss data. 2) Is the ledger fragments is not adhering placement policy. The one fragment maybe meet both case at the same time. If so, we will ignore case 2, just repaired the data loss. If the repaired result is not adhering the placement policy, the auditor will mark it again._


-- 
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-unsubscribe@bookkeeper.apache.org

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