Dan Burkert has posted comments on this change. ( http://gerrit.cloudera.org:8080/8254 )
Change subject: catalog manager: fix DDL race ...................................................................... Patch Set 3: (8 comments) http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/catalog_manager.h File src/kudu/master/catalog_manager.h: http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/catalog_manager.h@726 PS2, Line 726: // Looks up the table and locks it with the provided lock mode. > This doesn't exist anymore. Done http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/catalog_manager.cc File src/kudu/master/catalog_manager.cc: http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/catalog_manager.cc@1517 PS2, Line 1517: // Ensure that between dropping the catalog manager lock and acquiring the > Maybe this would be simpler as: Done http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/catalog_manager.cc@1519 PS2, Line 1519: // a concurrent rename table, try again to find the table. : TableMetadataLock lock(table_info->get(), lock_mode); > If this happens, why is it important to retry instead of returning "no tabl Done http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/catalog_manager.cc@1522 PS2, Line 1522: > Why is it sufficient to look at table_lock->data().name() and not also at t My understanding is that it's sufficient to check the table metadata since any alter table takes the table metadata lock exclusively, so it can't race with a FindAndLockTable. http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/master-test.cc File src/kudu/master/master-test.cc: http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/master-test.cc@1368 PS2, Line 1368: req.mutable_table()->set_table_name(kTableName); > Nit: pedantry, but would you mind formatting these lines in the same way as Done http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/master-test.cc@1371 PS2, Line 1371: > Does this (and the same in dropper) actually have any effect? I thought it Done http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/master/master-test.cc@1394 PS2, Line 1394: > Should be CHECK_OK, since it's a separate thread. Done http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/util/cow_object.h File src/kudu/util/cow_object.h: http://gerrit.cloudera.org:8080/#/c/8254/2/src/kudu/util/cow_object.h@171 PS2, Line 171: // An unlocked CowLock. This is useful for default constructing a lock to be > Might want to add that this is only useful for moving, since there's no exp Done -- To view, visit http://gerrit.cloudera.org:8080/8254 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I84ca3b207da28cd7dc43a077736da9b4e0ec6f37 Gerrit-Change-Number: 8254 Gerrit-PatchSet: 3 Gerrit-Owner: Dan Burkert <[email protected]> Gerrit-Reviewer: Adar Dembo <[email protected]> Gerrit-Reviewer: Dan Burkert <[email protected]> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Tidy Bot Gerrit-Comment-Date: Wed, 11 Oct 2017 20:59:01 +0000 Gerrit-HasComments: Yes
