Alexey Serbin has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/17097 )

Change subject: KUDU-2612: add ScopedPartitionLock
......................................................................


Patch Set 13: Code-Review+1

(6 comments)

http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager-test.cc
File src/kudu/tablet/lock_manager-test.cc:

http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager-test.cc@267
PS13, Line 267:           }
nit: does it make sense to add an ASSERT to make sure the lock is either 
acquired or the 'code' is one of two options,  but nothing else?


http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager-test.cc@270
PS13, Line 270:       // Have each transaction attempt to lock one lock manager 
and then the
Very nice scenario -- thank you for adding this one.


http://gerrit.cloudera.org:8080/#/c/17097/6/src/kudu/tablet/lock_manager.h
File src/kudu/tablet/lock_manager.h:

http://gerrit.cloudera.org:8080/#/c/17097/6/src/kudu/tablet/lock_manager.h@193
PS6, Line 193:  lock is released w
> Ah makes sense. Sorry I missed that! Thanks a lot for pointing out.
Not a problem at all: most importantly that's fixed now.  Thank you very much 
for addressing this!


http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager.cc
File src/kudu/tablet/lock_manager.cc:

http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager.cc@485
PS13, Line 485:       const MonoDelta elapsed(MonoTime::Now() - start);
nit: is it possible to move this under the 'if (timeout.Initialized())' case to 
avoid making calls to MonoTime::Now() if 'timeout' isn't initialized?


http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager.cc@521
PS13, Line 521:   PartitionLockState* lock;
              :   lock = TryAcquirePartitionLock(txn_id, &code, MonoDelta());
nit: combine these two lines into a single one?


http://gerrit.cloudera.org:8080/#/c/17097/13/src/kudu/tablet/lock_manager.cc@522
PS13, Line 522: MonoDelta()
nit: maybe, change the signature of this method to make this last parameter a 
parameter by default?



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

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I158115739ce3e7cfb77bbcb854e834336c1256b1
Gerrit-Change-Number: 17097
Gerrit-PatchSet: 13
Gerrit-Owner: Hao Hao <hao....@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <aser...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Bankim Bhavsar <ban...@cloudera.com>
Gerrit-Reviewer: Hao Hao <hao....@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Tue, 23 Mar 2021 06:44:50 +0000
Gerrit-HasComments: Yes

Reply via email to