kyuubi/extensions
liangbowen b346fb0845
[KYUUBI #4084] [Authz] Implicitly extracting name of Extractors and OperationType in spec file generation preventing use class name String directly
### _Why are the changes needed?_

- add implicit methods `classSimpleName` and `operationTypeStr` to package object `org.apache.kyuubi.plugin.spark.authz` in test sources
- increase compilation alignment to extractor itself, and easier use for future third party adaptation avoiding calling wrong `getName` of the calss
- preventing use String or class name as magic value directly which easily causes mistakes
- no changes with spec JSON file regeneration after this PR

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #4084 from bowenliang123/authz-class-simplename.

Closes #4084

54b831002 [liangbowen] simplify classSimpleName
1e191d51a [liangbowen] apply operationTypeStr to TableCommands
a1ea7a4e5 [liangbowen] apply operationTypeStr to DatabaseCommands
be6e7f2e3 [liangbowen] use classSimpleName implicitly
88332ff01 [liangbowen] make operationTypeStr method implicit
7eb023491 [liangbowen] add operationTypeStr method for extracting OperationType name
86bc45274 [liangbowen] replace AuthZUtils's extractorKey method by adding implicit classSimpleName methond in package object of `org.apache.kyuubi.plugin.spark.authz`
eece16ce8 [liangbowen] rename method to `extractorKey`. add method comments.
b36382c4c [liangbowen] refactor and rename to extractorName
0dd2b1043 [liangbowen] apply getClassSimpleName to DatabaseCommands
bd3ea8aa3 [liangbowen] apply getClassSimpleName to IcebergCommands
1026fbdcb [liangbowen] apply getClassSimpleName to TableCommands
9b06872f4 [liangbowen] apply getClassSimpleName to FunctionCommands
cb8494aef [liangbowen] apply getClassSimpleName to IcebergCommands
b787e72ee [liangbowen] apply getClassSimpleName to Scans
3ab171f18 [liangbowen] add getClassSimpleName method in AuthZUtils for getting class's simple name

Authored-by: liangbowen <liangbowen@gf.com.cn>
Signed-off-by: Kent Yao <yao@apache.org>
2023-01-05 13:59:33 +08:00
..
server/kyuubi-server-plugin [KYUUBI #3897] Supplying pluggable GroupProvider 2022-12-05 19:30:33 +08:00
spark [KYUUBI #4084] [Authz] Implicitly extracting name of Extractors and OperationType in spec file generation preventing use class name String directly 2023-01-05 13:59:33 +08:00
README.md [KYUUBI #2292] Unify kyuubi server plugin location 2022-04-08 10:16:11 +08:00

For developers

This folder contains plugins/extension for kyuubi server and different engine types.

  • ext
    • kyuubi-server
    • spark
    • flink
    • trino
    • hive
    • others
    • ...