liuml07 commented on code in PR #26781:
URL: https://github.com/apache/flink/pull/26781#discussion_r2201446402
##########
flink-table/flink-sql-gateway/src/main/java/org/apache/flink/table/gateway/service/operation/OperationExecutor.java:
##########
@@ -193,6 +194,7 @@ public ResultFetcher configureSession(OperationHandle
handle, String statement)
String.format(
"Unsupported statement for configuring
session:%s\n"
+ "The configureSession API only supports
to execute statement of type "
+ + "SET, RESET, "
Review Comment:
Currently there is no "operation name" available for operations. There is a
`asSummaryString` in the interface but it's at instance level which returns the
whole clause of the operation with values/properties.
Existing code has separated operation check and error messages. We can try
to consolidate them with a variable - a Map of allowed Operations and their
names. It would be easier when adding new operations. Let me update the code.
The main difference is, the new way does not group operations by semantics
as the existing code does. For e.g. all database related messages are currently
placed together, as seen `"CREATE DATABASE, DROP DATABASE, ALTER DATABASE, "`.
I think that probably is fine if we group by operations.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]