You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "luozenglin (via GitHub)" <gi...@apache.org> on 2023/06/27 02:40:25 UTC

[GitHub] [doris] luozenglin commented on a diff in pull request #21174: [improvement](workloadgroup)add check when drop/set workload group

luozenglin commented on code in PR #21174:
URL: https://github.com/apache/doris/pull/21174#discussion_r1243073422


##########
fe/fe-core/src/main/java/org/apache/doris/mysql/privilege/UserProperty.java:
##########
@@ -305,6 +305,10 @@ public void update(List<Pair<String, String>> properties) throws UserException {
                 if (keyArr.length != 1) {
                     throw new DdlException(PROP_WORKLOAD_GROUP + " format error");
                 }
+                boolean ret = Env.getCurrentEnv().getWorkloadGroupMgr().isWorkloadGroupExists(value);

Review Comment:
   might add a authentication, like `Env.getCurrentEnv().getAccessManager()
   .checkWorkloadGroupPriv(ConnectContext.get(), value, PrivPredicate.USAGE)`



-- 
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: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org