You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Hao Hao (Code Review)" <ge...@cloudera.org> on 2020/04/10 18:21:31 UTC

[kudu-CR](branch-1.12.x) KUDU-3078 Add Ranger tests to master authz-itest

Hao Hao has uploaded this change for review. ( http://gerrit.cloudera.org:8080/15712


Change subject: KUDU-3078 Add Ranger tests to master_authz-itest
......................................................................

KUDU-3078 Add Ranger tests to master_authz-itest

This commit refactors the existing Sentry integration tests to prepare
for Ranger integration tests.

It changes HMS and Sentry integration test base classes to test
harnesses that don't inherit from Gtest to simplify inheritance when
using typed tests.

master_sentry-itest is renamed to master_authz-itest to generalize it,
and most tests are changed to also run with Ranger. Those that aren't
test behavior specific to Sentry. A later patch will do the same for
ts_sentry-itest.

Ranger doesn't support adding new policy items (users and privileges) to
existing policies, so MiniRanger::AddPolicy stores policies in a member
variable and recreates them completely when a new item is added to an
existing policy (resource).

Change-Id: I25dc67516cd61f0624914989f8db4c4f94d7e3bf
Reviewed-on: http://gerrit.cloudera.org:8080/15681
Tested-by: Kudu Jenkins
Reviewed-by: Andrew Wong <aw...@cloudera.com>
(cherry picked from commit dacb8203f05ca2d873d524501214bfe5144ac9bb)
---
M src/kudu/integration-tests/CMakeLists.txt
M src/kudu/integration-tests/hms_itest-base.cc
M src/kudu/integration-tests/hms_itest-base.h
A src/kudu/integration-tests/master_authz-itest.cc
M src/kudu/integration-tests/master_hms-itest.cc
D src/kudu/integration-tests/master_sentry-itest.cc
M src/kudu/integration-tests/ts_sentry-itest.cc
M src/kudu/ranger/mini_ranger-test.cc
M src/kudu/ranger/mini_ranger.cc
M src/kudu/ranger/mini_ranger.h
10 files changed, 1,881 insertions(+), 1,303 deletions(-)



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

Gerrit-Project: kudu
Gerrit-Branch: branch-1.12.x
Gerrit-MessageType: newchange
Gerrit-Change-Id: I25dc67516cd61f0624914989f8db4c4f94d7e3bf
Gerrit-Change-Number: 15712
Gerrit-PatchSet: 1
Gerrit-Owner: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Attila Bukor <ab...@apache.org>

[kudu-CR](branch-1.12.x) KUDU-3078 Add Ranger tests to master authz-itest

Posted by "Hao Hao (Code Review)" <ge...@cloudera.org>.
Hao Hao has posted comments on this change. ( http://gerrit.cloudera.org:8080/15712 )

Change subject: KUDU-3078 Add Ranger tests to master_authz-itest
......................................................................


Patch Set 2: Code-Review+2


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

Gerrit-Project: kudu
Gerrit-Branch: branch-1.12.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I25dc67516cd61f0624914989f8db4c4f94d7e3bf
Gerrit-Change-Number: 15712
Gerrit-PatchSet: 2
Gerrit-Owner: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Attila Bukor <ab...@apache.org>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Comment-Date: Fri, 10 Apr 2020 20:50:20 +0000
Gerrit-HasComments: No

[kudu-CR](branch-1.12.x) KUDU-3078 Add Ranger tests to master authz-itest

Posted by "Hao Hao (Code Review)" <ge...@cloudera.org>.
Hao Hao has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/15712 )

Change subject: KUDU-3078 Add Ranger tests to master_authz-itest
......................................................................

KUDU-3078 Add Ranger tests to master_authz-itest

This commit refactors the existing Sentry integration tests to prepare
for Ranger integration tests.

It changes HMS and Sentry integration test base classes to test
harnesses that don't inherit from Gtest to simplify inheritance when
using typed tests.

master_sentry-itest is renamed to master_authz-itest to generalize it,
and most tests are changed to also run with Ranger. Those that aren't
test behavior specific to Sentry. A later patch will do the same for
ts_sentry-itest.

Ranger doesn't support adding new policy items (users and privileges) to
existing policies, so MiniRanger::AddPolicy stores policies in a member
variable and recreates them completely when a new item is added to an
existing policy (resource).

Change-Id: I25dc67516cd61f0624914989f8db4c4f94d7e3bf
Reviewed-on: http://gerrit.cloudera.org:8080/15681
Tested-by: Kudu Jenkins
Reviewed-by: Andrew Wong <aw...@cloudera.com>
(cherry picked from commit dacb8203f05ca2d873d524501214bfe5144ac9bb)
Reviewed-on: http://gerrit.cloudera.org:8080/15712
Reviewed-by: Hao Hao <ha...@cloudera.com>
---
M src/kudu/integration-tests/CMakeLists.txt
M src/kudu/integration-tests/hms_itest-base.cc
M src/kudu/integration-tests/hms_itest-base.h
A src/kudu/integration-tests/master_authz-itest.cc
M src/kudu/integration-tests/master_hms-itest.cc
D src/kudu/integration-tests/master_sentry-itest.cc
M src/kudu/integration-tests/ts_sentry-itest.cc
M src/kudu/ranger/mini_ranger-test.cc
M src/kudu/ranger/mini_ranger.cc
M src/kudu/ranger/mini_ranger.h
10 files changed, 1,881 insertions(+), 1,303 deletions(-)

Approvals:
  Kudu Jenkins: Verified
  Hao Hao: Looks good to me, approved

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

Gerrit-Project: kudu
Gerrit-Branch: branch-1.12.x
Gerrit-MessageType: merged
Gerrit-Change-Id: I25dc67516cd61f0624914989f8db4c4f94d7e3bf
Gerrit-Change-Number: 15712
Gerrit-PatchSet: 3
Gerrit-Owner: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com>
Gerrit-Reviewer: Attila Bukor <ab...@apache.org>
Gerrit-Reviewer: Hao Hao <ha...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)