keith-turner commented on code in PR #4524:
URL: https://github.com/apache/accumulo/pull/4524#discussion_r1631616426
##########
core/src/main/java/org/apache/accumulo/core/fate/MetaFateStore.java:
##########
@@ -315,6 +420,30 @@ public List<ReadOnlyRepo<T>> getStack() {
return dops;
}
}
+
+ @Override
+ protected void unreserve() {
+ try {
+ if (!this.deleted) {
+ zk.mutateExisting(getTXPath(fateId), currSerNodeVal -> {
+ NodeValue currNodeVal = new NodeValue(currSerNodeVal);
+ FateKey currFateKey = currNodeVal.fateKey.orElse(null);
+ if ((currNodeVal.isReserved()
+ &&
currNodeVal.reservation.orElseThrow().equals(this.reservation))) {
+ // Remove the FateReservation from the NodeValue to unreserve
+ return new NodeValue(currNodeVal.status, null,
currFateKey).serialize();
+ } else {
+ // possible this is running a 2nd time in zk server fault
conditions and its first
Review Comment:
Could add some logging here. If the reservation in ZK is not set, then
could log something at trace. If there is a reservation in ZK that differs, it
could log something at debug. These logs may be useful later for debugging
problems when initially using the elasticity changes.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]