Dinesh Bhat has uploaded a new change for review.

  http://gerrit.cloudera.org:8080/3823

Change subject: KUDU-1500: This intends to fix the data race observed by TSAN 
during one of the raft consensus tests.
......................................................................

KUDU-1500: This intends to fix the data race observed by TSAN during
one of the raft consensus tests.

The test intends to corrupt the metadata of one of the tserver tablets.
While the cluster is in the process of resurrecting the corrupt metadata,
the partition schema is accessed in an unguarded manner from another
thread servicing ListTablets API.

The proposed fix here accesses the metadata partition resources via
copy by value mechanism now in slow paths, where copy itself happens
under the same lock which makes the metadata resurrection operation
idempotent. Fast paths are untouched since the parition schema is
bound to be visible only after tablet metadata is resurrected.

Testing: Passed about 2000 iteration of the failing test
raft_consensus-itest.TestCorruptReplicaMetadata

Change-Id: If57617e22b41296b8d4e8ad131220f1ebb235019
---
M src/kudu/tablet/tablet.cc
M src/kudu/tablet/tablet_bootstrap.cc
M src/kudu/tablet/tablet_bootstrap.h
M src/kudu/tablet/tablet_metadata.h
M src/kudu/tablet/tablet_peer.cc
M src/kudu/tools/fs_tool.cc
M src/kudu/tserver/tablet_service.cc
M src/kudu/tserver/tserver-path-handlers.cc
8 files changed, 25 insertions(+), 18 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/23/3823/1
-- 
To view, visit http://gerrit.cloudera.org:8080/3823
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If57617e22b41296b8d4e8ad131220f1ebb235019
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Dinesh Bhat <din...@cloudera.com>

Reply via email to