Andrew Wong has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/12815 )

Change subject: tserver: sanitize write op types
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/12815/1/src/kudu/tablet/transactions/write_transaction.cc
File src/kudu/tablet/transactions/write_transaction.cc:

http://gerrit.cloudera.org:8080/#/c/12815/1/src/kudu/tablet/transactions/write_transaction.cc@301
PS1, Line 301:     EmplaceIfNotPresent(&op_types_, op.type);
> curious why you took this approach of storing it in a map vs just doing val
Yeah, just for the purposes of sanitizing, doing this in in the decoder makes 
sense.

This is actually fallout from authorization work, where having a set of the 
write operations is slightly more useful (i.e. it'd be relatively 
straightforward to compare the op types you're allowed to do with what op types 
you're trying to do). There's a case to be made for doing that in the decoder 
too that I hadn't considered, but it starts to blur the abstractions; I'll 
think about it.



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

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ib27c335e6a68336b88f75eb8fa2c45c6e18403d5
Gerrit-Change-Number: 12815
Gerrit-PatchSet: 1
Gerrit-Owner: Andrew Wong <[email protected]>
Gerrit-Reviewer: Andrew Wong <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Todd Lipcon <[email protected]>
Gerrit-Comment-Date: Wed, 20 Mar 2019 19:18:00 +0000
Gerrit-HasComments: Yes

Reply via email to