kyuubi/externals
Xianxun Ye d4320e7a6b [KYUUBI #5505][FLINK] Support HELP command
### _Why are the changes needed?_

resolve: #5505

Show available commands when users type 'HELP;' in the beeline.

#### Solution:

- Using `ExtendedParser` parse statement and return Operation of Flink engine.
- Check whether the operation is HelpOperation or not.
- dependency on `flink-table-planner-loader.jar`.

#### **Why not using Flink SQL Client Parser(SqlCommandParserImpl) to obtain the Command enum?**
Flink 1.16's approach:
```
val opt:Optional[Operation] = org.apache.flink.table.client.cli.SqlCommandParserImpl.parseCommand()
check opt.get() instance of HelpOperation or not
if yes return CliStrings.MESSAGE_HELP
```

Flink 1.17 & 1.18
```
val opt: Optional[Command] = org.apache.flink.table.client.cli.parser.SqlCommandParserImpl.parseStatement()
check opt.get() is Command.HELP or not
if yes return CliStrings.MESSAGE_HELP
```

The `Command` class is added from Flink1.17;
The `SqlCommandParserImpl` package is changed, and the method name is changed from Flink1.17;

This approach requires distinguishing between different Flink versions and maintaining both implementations.
It's more complicated, so abandoned.

### _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.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?_

Closes #5585 from YesOrNo828/help.

Closes #5505

e73b15e43 [Xianxun Ye] [KYUUBI #5505] [FLINK] Add job,update,delete,truncate and call statements
5943dd072 [Xianxun Ye] [KYUUBI #5505] [FLINK] Add help messages
fdc2db6ab [Xianxun Ye] [KYUUBI #5505] [FLINK] Support HELP command, fixed Pan's comments
a728048fc [Xianxun Ye] [KYUUBI #5505] [FLINK] Support HELP command, fixed Pan's comments
6323cfb85 [Xianxun Ye] [KYUUBI #5505] [FLINK] Support HELP command

Authored-by: Xianxun Ye <yesorno828423@gmail.com>
Signed-off-by: Paul Lin <paullin3280@gmail.com>
2023-11-07 15:09:57 +08:00
..
kyuubi-chat-engine [KYUUBI #5365] Don't use Log4j2's extended throwable conversion pattern in default logging configurations 2023-10-11 21:41:22 +08:00
kyuubi-download Bump 1.9.0-SNAPSHOT 2023-09-04 14:23:12 +08:00
kyuubi-flink-sql-engine [KYUUBI #5505][FLINK] Support HELP command 2023-11-07 15:09:57 +08:00
kyuubi-hive-sql-engine [KYUUBI #5365] Don't use Log4j2's extended throwable conversion pattern in default logging configurations 2023-10-11 21:41:22 +08:00
kyuubi-jdbc-engine [KYUUBI #5570] Fix memory leak when using incremental collect mode in JDBC engine 2023-11-01 21:48:21 +08:00
kyuubi-spark-sql-engine [KYUUBI #4186] Spark showProgress with JobInfo 2023-10-25 19:08:01 +08:00
kyuubi-trino-engine [KYUUBI #5282] Support configure Trino session conf in kyuubi-default.conf 2023-10-24 16:19:44 +08:00