-
Notifications
You must be signed in to change notification settings - Fork 924
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[KYUUBI #5306] YarnApplicationOperation supports proxy user
### _Why are the changes needed?_ For the secured YARN cluster, the Kyuubi Server's user typically has no permission to kill the application. Proxy user or admin should be used instead. https://docs.cloudera.com/documentation/enterprise/latest/topics/cm_mc_yarn_acl.html#concept_yarn_app_acls__section_killing_an_app > For YARN, the following three groups of users are allowed to kill a running application: > - The application owner > - A cluster administrator defined in yarn.admin.acl > - A queue administrator defined in aclAdministerApps for the queue in which the application is running ### _How was this patch tested?_ - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible - [x] Add screenshots for manual tests if appropriate Verified ADMIN mode in internal deployment. (output message is formatted for readable) ``` Error: Batch e351185f-1ed8-437a-91bf-da2174e611e2 failed: { "id":"e351185f-1ed8-437a-91bf-da2174e611e2", "user":"da_music", "batchType":"SPARK", "name":"SparkPi", "appStartTime":0, "appId":"application_1694730881181_58306", "appUrl":"http://xxxx-rm-2.xxxx:8088/cluster/app/application_1694730881181_58306", "appState":"KILLED", "appDiagnostic":"Application application_1694730881181_58306 was killed by user yarn at 10.49.59.149", "kyuubiInstance":"kyuubi-1.kyuubi-headless.spark.svc.cluster.local:10099", "state":"CANCELED", "createTime":1695102138188, "endTime":1695102163341, "batchInfo":{} } ``` - [ ] [Run test](https://kyuubi.readthedocs.io/en/master/contributing/code/testing.html#running-tests) locally before make a pull request ### _Was this patch authored or co-authored using generative AI tooling?_ No. Closes #5306 from pan3793/kill-proxy-user. Closes #5306 2b2e543 [Cheng Pan] address comments e7e9a9c [Cheng Pan] nit 9cf2afc [Cheng Pan] polish ff82d12 [Cheng Pan] polish bf0057b [Cheng Pan] ApplicationManager supports proxy user Authored-by: Cheng Pan <[email protected]> Signed-off-by: Cheng Pan <[email protected]>
- Loading branch information
Showing
11 changed files
with
193 additions
and
91 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -460,6 +460,13 @@ You can configure the Kyuubi properties in `$KYUUBI_HOME/conf/kyuubi-defaults.co | |
| kyuubi.spnego.keytab | <undefined> | Keytab file for SPNego principal | string | 1.6.0 | | ||
| kyuubi.spnego.principal | <undefined> | SPNego service principal, typical value would look like HTTP/_[email protected]. SPNego service principal would be used when restful Kerberos security is enabled. This needs to be set only if SPNEGO is to be used in authentication. | string | 1.6.0 | | ||
|
||
### Yarn | ||
|
||
| Key | Default | Meaning | Type | Since | | ||
|---------------------------|---------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------|-------| | ||
| kyuubi.yarn.user.admin | yarn | When kyuubi.yarn.user.strategy is set to ADMIN, use this admin user to construct YARN client for application management, e.g. kill application. | string | 1.8.0 | | ||
| kyuubi.yarn.user.strategy | NONE | Determine which user to use to construct YARN client for application management, e.g. kill application. Options: <ul><li>NONE: use Kyuubi server user.</li><li>ADMIN: use admin user configured in `kyuubi.yarn.user.admin`.</li><li>OWNER: use session user, typically is application owner.</li></ul> | string | 1.8.0 | | ||
|
||
### Zookeeper | ||
|
||
| Key | Default | Meaning | Type | Since | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.