dengzhhu653 commented on code in PR #6549:
URL: https://github.com/apache/hive/pull/6549#discussion_r3532841138
##########
ql/src/java/org/apache/hadoop/hive/ql/security/authorization/command/CommandAuthorizerV2.java:
##########
@@ -84,6 +86,17 @@ static void doAuthorization(HiveOperation op,
BaseSemanticAnalyzer sem, SessionS
ss.getAuthorizerV2().checkPrivileges(hiveOpType, inputsHObjs, outputHObjs,
authzContextBuilder.build());
}
+ private static void enrichAvroSchemaUrlInputs(List<ReadEntity> inputList)
throws HiveException {
+ List<ReadEntity> snapshot = new ArrayList<>(inputList);
+ for (ReadEntity readEntity : snapshot) {
+ try {
+ AuthorizationUtils.addAvroSchemaUrlInputForReadEntity(inputList,
readEntity);
+ } catch (SemanticException e) {
+ throw new HiveException("Failed to authorize avro.schema.url for " +
readEntity.getName(), e);
Review Comment:
if we remove the `SemanticException`, we don't need explicit catch for this
exception
--
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]