You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@impala.apache.org by "Austin Nobis (Code Review)" <ge...@cloudera.org> on 2019/02/28 17:50:48 UTC
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Austin Nobis has uploaded this change for review. ( http://gerrit.cloudera.org:8080/12637
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
IMPALA-7916: Remove support for authorization policy file flag
This patch removes support for the flag --authorization_policy_file.
The flag can still be passed to the backend but a warning message will
be logged in the frontend that the policy file has no effect on
authorization.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
12 files changed, 232 insertions(+), 483 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/1
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 1
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 4:
(2 comments)
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@183
PS4, Line 183: List<? extends FeDb> dbs = authzFe_.getDbs(PatternMatcher.createHivePatternMatcher("*"),
line too long (92 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/4/tests/authorization/test_authorization.py
File tests/authorization/test_authorization.py:
http://gerrit.cloudera.org:8080/#/c/12637/4/tests/authorization/test_authorization.py@42
PS4, Line 42: from tests.util.calculation_util import get_random_id
flake8: F401 'tests.util.calculation_util.get_random_id' imported but unused
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 4
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 01 Mar 2019 16:26:55 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 6:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2338/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 6
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 04 Mar 2019 19:20:07 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 1:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2301/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 1
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 18:29:03 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 5:
(4 comments)
http://gerrit.cloudera.org:8080/#/c/12637/5//COMMIT_MSG
Commit Message:
http://gerrit.cloudera.org:8080/#/c/12637/5//COMMIT_MSG@7
PS5, Line 7: flag
:
nit: remove
http://gerrit.cloudera.org:8080/#/c/12637/5//COMMIT_MSG@9
PS5, Line 9: This patch removes support for the flag --authorization_policy_file.
: The flag can still be passed to the backend but a warning message will
: be logged in the frontend that the policy file has no effect on
: authorization.
mention that the tests that rely on sentry authorization policy file have been rewritten to use sentry service instead.
http://gerrit.cloudera.org:8080/#/c/12637/5/fe/src/main/java/org/apache/impala/service/JniFrontend.java
File fe/src/main/java/org/apache/impala/service/JniFrontend.java:
http://gerrit.cloudera.org:8080/#/c/12637/5/fe/src/main/java/org/apache/impala/service/JniFrontend.java@711
PS5, Line 711: if (BackendConfig.INSTANCE.isAuthorizationFileSet()) {
: LOG.warn("authorization_policy_file flag is no longer supported. The " +
: "flag is being ignored.");
: }
We should handle it in the backend instead. See: https://github.com/apache/impala/blob/master/be/src/common/global-flags.cc#L299-L334. In other words, we need to remove the authorization_file property from Thrift.
http://gerrit.cloudera.org:8080/#/c/12637/4/tests/authorization/test_authorization.py
File tests/authorization/test_authorization.py:
http://gerrit.cloudera.org:8080/#/c/12637/4/tests/authorization/test_authorization.py@42
PS4, Line 42: from tests.util.filesystem_utils import WAREHOUSE
> flake8: F401 'tests.util.calculation_util.get_random_id' imported but unuse
Done
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 5
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 01 Mar 2019 18:30:40 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
IMPALA-7918: Remove support for authorization policy file
This patch removes support for the authorization_policy_file. When the
flag is passed, the backend will issue a warning message that the flag
is being ignored.
Tests relying on the authorization_policy_file flag have been updated to
rely on sentry server instead.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Reviewed-on: http://gerrit.cloudera.org:8080/12637
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
M be/src/common/global-flags.cc
M be/src/service/frontend.cc
M be/src/util/backend-gflag-util.cc
M common/thrift/BackendGflags.thrift
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationFactory.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/BackendConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationStmtTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
22 files changed, 427 insertions(+), 1,005 deletions(-)
Approvals:
Impala Public Jenkins: Looks good to me, approved; Verified
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 12
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 7: Code-Review+1
LGTM, thanks! Will be bumping it to +2 to avoid a lot of merge conflicts with other CRs.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 7
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Tue, 05 Mar 2019 16:37:27 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 3:
(1 comment)
http://gerrit.cloudera.org:8080/#/c/12637/3/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/3/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@103
PS3, Line 103: private final SentryAuthorizationConfig sentryServiceAuthzConfig_ = handleImpalaException(
line too long (92 > 90)
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 3
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 20:40:53 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 9:
(3 comments)
http://gerrit.cloudera.org:8080/#/c/12637/9/be/src/service/frontend.cc
File be/src/service/frontend.cc:
http://gerrit.cloudera.org:8080/#/c/12637/9/be/src/service/frontend.cc@49
PS9, Line 49: By default, the "
: "authorization policy will be loaded from the catalog server (via the statestore).
I removed this comment from my earlier patch since this is no longer correct.
http://gerrit.cloudera.org:8080/#/c/12637/9/fe/src/main/java/org/apache/impala/service/Frontend.java
File fe/src/main/java/org/apache/impala/service/Frontend.java:
http://gerrit.cloudera.org:8080/#/c/12637/9/fe/src/main/java/org/apache/impala/service/Frontend.java@260
PS9, Line 260: if (authzConfig.getProvider() == AuthorizationProvider.SENTRY) {
: SentryAuthorizationConfig sentryAuthzConfig =
: (SentryAuthorizationConfig) authzConfig;
: authzChecker_.set(new SentryAuthorizationChecker(sentryAuthzConfig,
: getCatalog().getAuthPolicy()));
: } else {
: authzChecker_.set(authzFactory.newAuthorizationChecker());
: }
we need to refactor this, e.g.
if (authzConfig.isEnabled()) { ... }
else { ... }
http://gerrit.cloudera.org:8080/#/c/12637/9/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/9/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@109
PS9, Line 109: // public AuthorizationTest(TestContext ctx) throws Exception {
why is this commented out?
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 9
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Sat, 23 Mar 2019 00:40:02 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 4:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2318/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 4
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 01 Mar 2019 17:09:19 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 5:
(3 comments)
http://gerrit.cloudera.org:8080/#/c/12637/5//COMMIT_MSG
Commit Message:
http://gerrit.cloudera.org:8080/#/c/12637/5//COMMIT_MSG@7
PS5, Line 7: flag
:
> nit: remove
Done
http://gerrit.cloudera.org:8080/#/c/12637/5//COMMIT_MSG@9
PS5, Line 9: This patch removes support for the flag --authorization_policy_file.
: The flag can still be passed to the backend but a warning message will
: be logged in the frontend that the policy file has no effect on
: authorization.
> mention that the tests that rely on sentry authorization policy file have b
Done
http://gerrit.cloudera.org:8080/#/c/12637/5/fe/src/main/java/org/apache/impala/service/JniFrontend.java
File fe/src/main/java/org/apache/impala/service/JniFrontend.java:
http://gerrit.cloudera.org:8080/#/c/12637/5/fe/src/main/java/org/apache/impala/service/JniFrontend.java@711
PS5, Line 711: if (BackendConfig.INSTANCE.isAuthorizationFileSet()) {
: LOG.warn("authorization_policy_file flag is no longer supported. The " +
: "flag is being ignored.");
: }
> We should handle it in the backend instead. See: https://github.com/apache/
Done
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 5
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 04 Mar 2019 18:40:40 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 3:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2304/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 3
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 21:23:16 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 4:
(5 comments)
Thanks! Overall it looks good now, just couple nits.
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@51
PS4, Line 51: import org.apache.impala.thrift.*;
nit: don't use wildcard imports
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@54
PS4, Line 54: import org.junit.*;
same thing here
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@68
PS4, Line 68: private static final SentryAuthorizationConfig authzConfig =
: SentryAuthorizationConfig.createHadoopGroupAuthConfig("server1",
: System.getenv("IMPALA_HOME") + "/fe/src/test/resources/sentry-site.xml");
: private static final ImpaladTestCatalog authzCatalog_ =
: new ImpaladTestCatalog(authzConfig);
: private static final Frontend authzFe_ = new Frontend(authzConfig, authzCatalog_);
static final variables should use upper case names
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@78
PS4, Line 78: analysisContext_
can we rename this to authzCtx to differentiate between normal ctx vs authz ctx?
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@80
PS4, Line 80: setupImpalaCatalog(authzCatalog_);
: } catch(ImpalaException e) {
: throw new RuntimeException(e);
: }
We can just declare the ImpalaException in the constructor.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 4
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 01 Mar 2019 17:37:13 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#9). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
IMPALA-7918: Remove support for authorization policy file
This patch removes support for the authorization_policy_file. When the
flag is passed, the backend will issue a warning message that the flag
is being ignored.
Tests relying on the authorization_policy_file flag have been updated to
rely on sentry server instead.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M be/src/common/global-flags.cc
M be/src/service/frontend.cc
M be/src/util/backend-gflag-util.cc
M common/thrift/BackendGflags.thrift
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationFactory.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/BackendConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationStmtTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
22 files changed, 443 insertions(+), 1,002 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/9
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 9
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#3). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
IMPALA-7916: Remove support for authorization policy file flag
This patch removes support for the flag --authorization_policy_file.
The flag can still be passed to the backend but a warning message will
be logged in the frontend that the policy file has no effect on
authorization.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
14 files changed, 308 insertions(+), 468 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/3
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 3
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 4:
(6 comments)
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@51
PS4, Line 51: import org.apache.impala.thrift.*;
> nit: don't use wildcard imports
Done
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@54
PS4, Line 54: import org.junit.*;
> same thing here
Done
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@68
PS4, Line 68: private static final SentryAuthorizationConfig authzConfig =
: SentryAuthorizationConfig.createHadoopGroupAuthConfig("server1",
: System.getenv("IMPALA_HOME") + "/fe/src/test/resources/sentry-site.xml");
: private static final ImpaladTestCatalog authzCatalog_ =
: new ImpaladTestCatalog(authzConfig);
: private static final Frontend authzFe_ = new Frontend(authzConfig, authzCatalog_);
> static final variables should use upper case names
Done
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@78
PS4, Line 78: analysisContext_
> can we rename this to authzCtx to differentiate between normal ctx vs authz
Done
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@80
PS4, Line 80: setupImpalaCatalog(authzCatalog_);
: } catch(ImpalaException e) {
: throw new RuntimeException(e);
: }
> We can just declare the ImpalaException in the constructor.
Done
http://gerrit.cloudera.org:8080/#/c/12637/4/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@183
PS4, Line 183: List<? extends FeDb> dbs = authzFe_.getDbs(PatternMatcher.createHivePatternMatcher("*"),
> line too long (92 > 90)
Done
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 4
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 01 Mar 2019 17:53:12 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 6:
(1 comment)
http://gerrit.cloudera.org:8080/#/c/12637/6/common/thrift/BackendGflags.thrift
File common/thrift/BackendGflags.thrift:
http://gerrit.cloudera.org:8080/#/c/12637/6/common/thrift/BackendGflags.thrift@47
PS6, Line 47: 10: required string server_name
Comment out and don't re-order the Thrift fields to make it backward compatible. See this as an example: https://github.com/apache/impala/blob/master/common/thrift/CatalogObjects.thrift#L339
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 6
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Tue, 05 Mar 2019 05:28:36 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 1:
(12 comments)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
File fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java:
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java@46
PS1, Line 46: public SentryAuthorizationConfig(String serverName, String sentryConfigFile, String policyProviderClassName) {
line too long (112 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java@73
PS1, Line 73: public static SentryAuthorizationConfig createHadoopGroupAuthConfig(String serverName, String sentryConfigFile) {
line too long (115 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java@128
PS1, Line 128: return !Strings.isNullOrEmpty(serverName_) || !Strings.isNullOrEmpty(sentryConfig_.getConfigFile());
line too long (104 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@828
PS1, Line 828: config = SentryAuthorizationConfig.createHadoopGroupAuthConfig("server1", sentryConfig);
line too long (92 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@866
PS1, Line 866: config = SentryAuthorizationConfig.createHadoopGroupAuthConfig("server1", "/path/does/not/exist.xml");
line too long (108 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@877
PS1, Line 877: config = new SentryAuthorizationConfig("server1", sentryConfig, "ClassDoesNotExist");
line too long (91 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@887
PS1, Line 887: config = new SentryAuthorizationConfig("server1", sentryConfig, this.getClass().getName());
line too long (97 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
File fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java@60
PS1, Line 60: SENTRY_SERVER, System.getenv("IMPALA_HOME") + "/fe/src/test/resources/sentry-site.xml");
line too long (96 > 90)
http://gerrit.cloudera.org:8080/#/c/12637/1/tests/authorization/test_authorization.py
File tests/authorization/test_authorization.py:
http://gerrit.cloudera.org:8080/#/c/12637/1/tests/authorization/test_authorization.py@67
PS1, Line 67:
flake8: E251 unexpected spaces around keyword / parameter equals
http://gerrit.cloudera.org:8080/#/c/12637/1/tests/authorization/test_authorization.py@67
PS1, Line 67:
flake8: E251 unexpected spaces around keyword / parameter equals
http://gerrit.cloudera.org:8080/#/c/12637/1/tests/authorization/test_authorization.py@77
PS1, Line 77:
flake8: E251 unexpected spaces around keyword / parameter equals
http://gerrit.cloudera.org:8080/#/c/12637/1/tests/authorization/test_authorization.py@77
PS1, Line 77:
flake8: E251 unexpected spaces around keyword / parameter equals
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 1
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 17:51:38 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 11: Verified+1
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 11
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 25 Mar 2019 20:23:32 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 3:
(12 comments)
http://gerrit.cloudera.org:8080/#/c/12637/3/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/3/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@24
PS3, Line 24: import java.util.*;
nit: don't use wildcard imports.
http://gerrit.cloudera.org:8080/#/c/12637/3/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@69
PS3, Line 69: // Policy file has defined current user and 'test_user' have:
: // ALL permission on 'tpch' database and 'newdb' database
: // ALL permission on 'functional_seq_snap' database
: // SELECT permissions on all tables in 'tpcds' database
: // SELECT, REFRESH, DROP permissions on 'functional.alltypesagg'
: // ALTER permissions on 'functional.alltypeserror'
: // SELECT permissions on 'functional.complex_view'
: // SELECT, REFRESH permissions on 'functional.view_view'
: // ALTER, DROP permissions on 'functional.alltypes_view'
: // SELECT permissions on columns ('id', 'int_col', and 'year') on
: // 'functional.alltypessmall' (no SELECT permissions on 'functional.alltypessmall')
: // SELECT permissions on columns ('id', 'int_struct_col', 'struct_array_col',
: // 'int_map_col') on 'functional.allcomplextypes' (no SELECT permissions on
: // 'functional.allcomplextypes')
: // ALL permissions on 'functional_parquet.allcomplextypes'
: // SELECT permissions on all the columns of 'functional.alltypestiny' (no SELECT
: // permissions on table 'functional.alltypestiny')
: // INSERT permissions on 'functional.alltypes' (no SELECT permissions)
: // INSERT permissions on all tables in 'functional_parquet' database
: // No permissions on database 'functional_rc'
: // Only column level permissions in 'functional_avro':
: // SELECT permissions on columns ('id') on 'functional_avro.alltypessmall'
: // REFRESH, INSERT, CREATE, ALTER, DROP permissions on 'functional_text_lzo' database
all these comments may no longer be relevant.
http://gerrit.cloudera.org:8080/#/c/12637/3/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@792
PS3, Line 792:
nit: indentation off
http://gerrit.cloudera.org:8080/#/c/12637/3/testdata/bin/create-load-data.sh
File testdata/bin/create-load-data.sh:
http://gerrit.cloudera.org:8080/#/c/12637/3/testdata/bin/create-load-data.sh@a299
PS3, Line 299:
authz-policy.ini.template file needs to be removed.
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py
File tests/authorization/test_authorization.py:
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@32
PS3, Line 32: from getpass import getuser
This is nice! Thanks for making it more readable.
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@67
PS3, Line 67: verify=True
add comment for verify is true and exception will be raised when there was an exception in HS2.
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@73
PS3, Line 73: if verify:
: TestHS2.check_response(result)
: return result
nit: can be simplified to return TestHS2.check_response(result) if verify else result
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@77
PS3, Line 77: verify=True
add comment as well.
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@83
PS3, Line 83: if verify:
: TestHS2.check_response(resp)
: return resp
nit; same as above
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@122
PS3, Line 122: unique_db = "test_access_runtime_profile_" + get_random_id(5)
Can you create a test fixture for unique_name? Sounds like it'll be a useful thing to have.
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@167
PS3, Line 167:
nit: indentation off
http://gerrit.cloudera.org:8080/#/c/12637/3/tests/authorization/test_authorization.py@253
PS3, Line 253: \
nit: i don't think it's necessary
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 3
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 21:13:53 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#2). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
IMPALA-7916: Remove support for authorization policy file flag
This patch removes support for the flag --authorization_policy_file.
The flag can still be passed to the backend but a warning message will
be logged in the frontend that the policy file has no effect on
authorization.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
12 files changed, 229 insertions(+), 477 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/2
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 2
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 7:
(1 comment)
http://gerrit.cloudera.org:8080/#/c/12637/7//COMMIT_MSG
Commit Message:
http://gerrit.cloudera.org:8080/#/c/12637/7//COMMIT_MSG@7
PS7, Line 7: IMPALA-7916
Wrong JIRA. Please update.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 7
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Tue, 05 Mar 2019 17:08:47 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#5). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
IMPALA-7916: Remove support for authorization policy file flag
This patch removes support for the flag --authorization_policy_file.
The flag can still be passed to the backend but a warning message will
be logged in the frontend that the policy file has no effect on
authorization.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
16 files changed, 411 insertions(+), 990 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/5
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 5
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 2:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2302/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 2
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 18:35:52 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 10:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2529/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 10
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 25 Mar 2019 16:02:03 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#4). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
IMPALA-7916: Remove support for authorization policy file flag
This patch removes support for the flag --authorization_policy_file.
The flag can still be passed to the backend but a warning message will
be logged in the frontend that the policy file has no effect on
authorization.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
16 files changed, 406 insertions(+), 992 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/4
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 4
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#8). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
IMPALA-7916: Remove support for authorization policy file
This patch removes support for the authorization_policy_file. When the
flag is passed, the backend will issue a warning message that the flag
is being ignored.
Tests relying on the authorization_policy_file flag have been updated to
rely on sentry server instead.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M be/src/common/global-flags.cc
M be/src/service/frontend.cc
M be/src/util/backend-gflag-util.cc
M common/thrift/BackendGflags.thrift
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationFactory.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/BackendConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationStmtTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
22 files changed, 443 insertions(+), 1,002 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/8
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 8
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#10). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
IMPALA-7918: Remove support for authorization policy file
This patch removes support for the authorization_policy_file. When the
flag is passed, the backend will issue a warning message that the flag
is being ignored.
Tests relying on the authorization_policy_file flag have been updated to
rely on sentry server instead.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M be/src/common/global-flags.cc
M be/src/service/frontend.cc
M be/src/util/backend-gflag-util.cc
M common/thrift/BackendGflags.thrift
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationFactory.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/BackendConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationStmtTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
22 files changed, 427 insertions(+), 1,005 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/10
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 10
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 11:
Build started: https://jenkins.impala.io/job/gerrit-verify-dryrun/3950/ DRY_RUN=false
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 11
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 25 Mar 2019 15:46:18 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 10: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 10
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 25 Mar 2019 15:46:03 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 9:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2527/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 9
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 22 Mar 2019 21:16:38 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 8:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2526/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 8
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 22 Mar 2019 21:12:22 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#6). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
IMPALA-7916: Remove support for authorization policy file
This patch removes support for the authorization_policy_file. When the
flag is passed, the backend will issue a warning message that the flag
is being ignored.
Tests relying on the authorization_policy_file flag have been updated to
rely on sentry server instead.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M be/src/common/global-flags.cc
M be/src/service/frontend.cc
M be/src/util/backend-gflag-util.cc
M common/thrift/BackendGflags.thrift
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/BackendConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
21 files changed, 451 insertions(+), 1,045 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/6
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 6
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 7:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2356/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 7
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Tue, 05 Mar 2019 16:59:44 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 9:
(1 comment)
http://gerrit.cloudera.org:8080/#/c/12637/7//COMMIT_MSG
Commit Message:
http://gerrit.cloudera.org:8080/#/c/12637/7//COMMIT_MSG@7
PS7, Line 7: IMPALA-7918
> Wrong JIRA. Please update.
Done
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 9
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 22 Mar 2019 20:32:33 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has uploaded a new patch set (#7). ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
IMPALA-7916: Remove support for authorization policy file
This patch removes support for the authorization_policy_file. When the
flag is passed, the backend will issue a warning message that the flag
is being ignored.
Tests relying on the authorization_policy_file flag have been updated to
rely on sentry server instead.
Testing:
- Ran all FE tests
- Ran all E2E tests
Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
---
M be/src/common/global-flags.cc
M be/src/service/frontend.cc
M be/src/util/backend-gflag-util.cc
M common/thrift/BackendGflags.thrift
M fe/src/main/java/org/apache/impala/analysis/AuthorizationStmt.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthProvider.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
M fe/src/main/java/org/apache/impala/authorization/sentry/SentryPolicyService.java
M fe/src/main/java/org/apache/impala/service/BackendConfig.java
M fe/src/main/java/org/apache/impala/service/Frontend.java
M fe/src/main/java/org/apache/impala/service/JniFrontend.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeAuthStmtsTest.java
M fe/src/test/java/org/apache/impala/analysis/AuditingTest.java
M fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
M fe/src/test/java/org/apache/impala/authorization/sentry/SentryProxyTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
M fe/src/test/java/org/apache/impala/service/CustomClusterGroupMapper.java
D fe/src/test/resources/authz-policy.ini.template
M testdata/bin/create-load-data.sh
M tests/authorization/test_authorization.py
M tests/conftest.py
21 files changed, 416 insertions(+), 1,008 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/37/12637/7
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 7
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
[Impala-ASF-CR] IMPALA-7918: Remove support for authorization policy file
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7918: Remove support for authorization policy file
......................................................................
Patch Set 11: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 11
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Mon, 25 Mar 2019 15:46:17 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Fredy Wijaya (Code Review)" <ge...@cloudera.org>.
Fredy Wijaya has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 2:
(6 comments)
I did a quick look at this CR and gave some quick comments. Will review more later.
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java
File fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java:
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java@22
PS1, Line 22: import org.apache.impala.authorization.AuthorizationConfig;
this import doesn't seem used.
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/authorization/sentry/SentryAuthorizationConfig.java@28
PS1, Line 28: * Impala authorization configuration with Sentry.
: */
: public class SentryAuthorizationCon
same thing with these imports
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/service/JniFrontend.java
File fe/src/main/java/org/apache/impala/service/JniFrontend.java:
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/main/java/org/apache/impala/service/JniFrontend.java@713
PS1, Line 713:
nit: indentation off
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java
File fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java:
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@a143
PS1, Line 143:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
We need to refactor this test. I don't think it makes sense to use parameterized JUnit anymore.
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@a834
PS1, Line 834:
we need this test.
http://gerrit.cloudera.org:8080/#/c/12637/1/fe/src/test/java/org/apache/impala/analysis/AuthorizationTest.java@a1026
PS1, Line 1026:
we need this test
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 2
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Thu, 28 Feb 2019 18:09:46 +0000
Gerrit-HasComments: Yes
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file flag
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file flag
......................................................................
Patch Set 5:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2320/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 5
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 01 Mar 2019 18:37:22 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-7916: Remove support for authorization policy file
Posted by "Austin Nobis (Code Review)" <ge...@cloudera.org>.
Austin Nobis has posted comments on this change. ( http://gerrit.cloudera.org:8080/12637 )
Change subject: IMPALA-7916: Remove support for authorization policy file
......................................................................
Patch Set 7:
(1 comment)
http://gerrit.cloudera.org:8080/#/c/12637/6/common/thrift/BackendGflags.thrift
File common/thrift/BackendGflags.thrift:
http://gerrit.cloudera.org:8080/#/c/12637/6/common/thrift/BackendGflags.thrift@47
PS6, Line 47: // REMOVED: 10: required string authorization_policy_file
> Comment out and don't re-order the Thrift fields to make it backward compat
Done
--
To view, visit http://gerrit.cloudera.org:8080/12637
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2a52c2d5d35f58fbff8c088fb0bf30169625ebd
Gerrit-Change-Number: 12637
Gerrit-PatchSet: 7
Gerrit-Owner: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Austin Nobis <an...@cloudera.com>
Gerrit-Reviewer: Fredy Wijaya <fw...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Tue, 05 Mar 2019 16:18:16 +0000
Gerrit-HasComments: Yes