deniskuzZ commented on code in PR #6148:
URL: https://github.com/apache/hive/pull/6148#discussion_r2473100982
##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/HMSHandler.java:
##########
@@ -8882,20 +8807,22 @@ public GetFunctionsResponse
get_functions_req(GetFunctionsRequest req)
RawStore ms = getMS();
Exception ex = null;
- List<Function> funcs = null;
+ GetFunctionsResponse response = new GetFunctionsResponse();
String catName = req.isSetCatalogName() ? req.getCatalogName() :
getDefaultCatalog(conf);
try {
- funcs = ms.getFunctionsRequest(catName, req.getDbName(),
+ List result = ms.getFunctionsRequest(catName, req.getDbName(),
req.getPattern(), req.isReturnNames());
+ if (req.isReturnNames()) {
+ response.setFunction_names(result);
+ } else {
+ response.setFunctions(result);
+ }
} catch (Exception e) {
ex = e;
throw newMetaException(e);
} finally {
- endFunction("get_functions", funcs != null, ex);
+ endFunction("get_functions", ex != null, ex);
Review Comment:
successful => (ex == null) ?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]