Adar Dembo has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/15207 )

Change subject: [WIP] Ranger authorization provider
......................................................................


Patch Set 20:

(3 comments)

http://gerrit.cloudera.org:8080/#/c/15207/16/src/kudu/master/ranger_authz_provider.cc
File src/kudu/master/ranger_authz_provider.cc:

http://gerrit.cloudera.org:8080/#/c/15207/16/src/kudu/master/ranger_authz_provider.cc@41
PS16, Line 41:
> We need to add this directory to the Java classpath. Should I list all file
Not sure. As it stands, there isn't enough information for a casual user to 
figure out what needs to be configured and how, and we need to fix that.


http://gerrit.cloudera.org:8080/#/c/15207/16/src/kudu/master/ranger_authz_provider.cc@184
PS16, Line 184:     column_names.emplace(col.name());
> We could, but that would be a lot of extra complexity and I'm not sure it's
I guess we can leave it this way for now if the alternative is more 
complicated. Could you a TODO? Basically we should revisit when we have a 
clearer sense of the sort of Ranger policies our users will create.


http://gerrit.cloudera.org:8080/#/c/15207/20/src/kudu/ranger/ranger_client-test.cc
File src/kudu/ranger/ranger_client-test.cc:

http://gerrit.cloudera.org:8080/#/c/15207/20/src/kudu/ranger/ranger_client-test.cc@71
PS20, Line 71:     int h_action = 
std::hash<int>{}(static_cast<int>(action.action));
             :     int h_column = std::hash<string>{}(action.column_name) << 1;
             :     int h_database = std::hash<string>{}(action.database_name) 
<< 2;
             :     int h_table = std::hash<string>{}(action.table_name) << 3;
             :     int h_user = std::hash<string>{}(action.user_name) << 4;
             :
             :     return h_action ^ h_column ^ h_database ^ h_table ^ h_user;
Use boost::hash_combine for stuff like this, a la ConnectionId:

  size_t ConnectionId::HashCode() const {
    size_t seed = 0;
    boost::hash_combine(seed, remote_.HashCode());
    boost::hash_combine(seed, hostname_);
    boost::hash_combine(seed, user_credentials_.HashCode());
    boost::hash_combine(seed, network_plane_);
    return seed;
  }



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

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I6e7672a5947d6406e0cad83a0c900bf5b2c03012
Gerrit-Change-Number: 15207
Gerrit-PatchSet: 20
Gerrit-Owner: Attila Bukor <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Andrew Wong <[email protected]>
Gerrit-Reviewer: Attila Bukor <[email protected]>
Gerrit-Reviewer: Hao Hao <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Wed, 04 Mar 2020 05:25:52 +0000
Gerrit-HasComments: Yes

Reply via email to