You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "Cai-Yao (via GitHub)" <gi...@apache.org> on 2023/04/13 04:24:46 UTC

[GitHub] [doris] Cai-Yao commented on a diff in pull request #18609: [Fix](variables) fix session variable does not take effect immediately when set global variable in follower FE

Cai-Yao commented on code in PR #18609:
URL: https://github.com/apache/doris/pull/18609#discussion_r1164980618


##########
fe/fe-core/src/main/java/org/apache/doris/qe/SetExecutor.java:
##########
@@ -59,9 +59,24 @@ private void setVariable(SetVar var) throws DdlException {
         }
     }
 
+    private boolean isSessionVar(SetVar var) {
+        return !(var instanceof SetPassVar

Review Comment:
   > This is error-prone, if other people at a new subclass of `SetVar`, this method may be missed. How about add a `SetVarType` or something to specify the stmt's type directly? And write like `return var.setType() == Type.SET_SESSION_VAR`;
   
   Yes, I will modify it.



-- 
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