[
https://issues.apache.org/jira/browse/BOOKKEEPER-272?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13440199#comment-13440199
]
Ivan Kelly commented on BOOKKEEPER-272:
---------------------------------------
{quote}
L0001 contains only BK1. while marking missingReplica of BK2, got NEE. Assume
there is already a missing replica. Silently return as you told
{quote}
No, In this case we need to add BK2 as a missingReplica also.
{quote}
L0001 contains only BK2. while marking missingReplica of BK2, got NEE. Assume
only single auditor and no other is marking. So again we need to merge to the
zkMetadata and update in zk.
{quote}
In this case we want to return. BK2 is already marked as a missingReplica, so
it will be picked up for replication anyhow.
The necessary change is:
{code}
} catch (KeeperException.NodeExistsException nee) {
Stat s = zkc.exists(znode, false);
if (s == null) {
continue;
}
try {
byte[] bytes = zkc.getData(znode, false, s);
TextFormat.merge(new String(bytes, UTF8), builder);
UnderreplicatedLedgerFormat data = builder.build();
for (String r : data.getReplicaList()) {
if (r.equals(missingReplica)) {
- break; // nothing to add
+ return; // nothing to add
}
}
builder.addReplica(missingReplica);
zkc.setData(znode,
TextFormat.printToString(builder.build()).getBytes(UTF8),
s.getVersion());
} catch (KeeperException.NoNodeException nne) {
continue;
} catch (KeeperException.BadVersionException bve) {
continue;
} catch (TextFormat.ParseException pe) {
throw new ReplicationException.UnavailableException(
"Invalid data found", pe);
}
}
break;
}
{code}
> Provide automatic mechanism to know bookie failures
> ---------------------------------------------------
>
> Key: BOOKKEEPER-272
> URL: https://issues.apache.org/jira/browse/BOOKKEEPER-272
> Project: Bookkeeper
> Issue Type: Sub-task
> Components: bookkeeper-auto-recovery
> Reporter: Rakesh R
> Assignee: Rakesh R
> Fix For: 4.2.0
>
> Attachments: BOOKKEEPER-272.1.patch, BOOKKEEPER-272.2.patch,
> BOOKKEEPER-272.3.patch, BOOKKEEPER-272.Auditor.1.patch,
> BOOKKEEPER-272.Auditor.patch
>
>
> The idea is to build automatic mechanism to find out the bookie failures.
> Setup the bookie failure notifications to start the re-replication process.
> There are multiple approaches to findout bookie failures. Please refer the
> documents attached in BookKeeper-237.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira