Mike Percy has submitted this change and it was merged.

Change subject: KUDU-2138 delete failed replicas in tablet report
......................................................................


KUDU-2138 delete failed replicas in tablet report

When a Kudu master processes a replica's tablet report, it will send a
DeleteTablet RPC if the replica is not already deleted, has a consensus
state, has a lower opid index than the latest reported committed config,
and is no longer in the tablet's Raft configuration.

Failed tablets are handled specially in processing the report to return
before any of the above checks can be made. This can lead to failed
tablets lingering when they should actually be deleted.

This patch fixes this by performing these checks and sending the delete
regardless of whether or not the tablet is failed (other than checking
the opid index, since failed tablets do not report an opid index).

A test is added to tablet_replacement-itest to fail a replica, evict but
not tombstone it, report it to the master, and ensure it is properly
deleted.

Change-Id: I34abd2cf4d00098a28dd7645053ccdc8341df03c
Reviewed-on: http://gerrit.cloudera.org:8080/7992
Tested-by: Kudu Jenkins
Reviewed-by: Mike Percy <mpe...@apache.org>
---
M src/kudu/integration-tests/tablet_replacement-itest.cc
M src/kudu/master/catalog_manager.cc
2 files changed, 102 insertions(+), 23 deletions(-)

Approvals:
  Mike Percy: Looks good to me, approved
  Kudu Jenkins: Verified



-- 
To view, visit http://gerrit.cloudera.org:8080/7992
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I34abd2cf4d00098a28dd7645053ccdc8341df03c
Gerrit-PatchSet: 6
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <a...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Mike Percy <mpe...@apache.org>

Reply via email to