yangyichao-mango commented on pull request #3243: URL: https://github.com/apache/incubator-dolphinscheduler/pull/3243#issuecomment-662193182
> 1. SqlParameters = = null, because the key parameters have been checked in the UI, where SqlParameters cannot be null > 2. For the exception of connection closing, the log should be added. In my opinion, if an exception occurs, the connection = = null > > 1. sqlParameters ==null , 因为在UI里面已经对关键参数进行校验,此处sqlParameters不可能为null > 2.针对connection关闭发生异常增加日志,我认为更应该如果发生异常将connection==null Hi, 1. In addition to using webui, users can also use API to create directly, and it can also solve the null value caused by errors in the JSON serialization process. Judging null value here actually can enhance the robustness of the code. Example: Although the value of a `String` cannot be null, we usually use the `StringUtils.isNotEmpty`, and it add the null value judgment. 2. Please point out where the code is. ----- 1.用户除了使用webui,也可以使用api直接创建,除此之外可以将将json序列化过程中出错导致的null值给解决。这里判断是否为null,可以增强代码鲁棒性。举例:虽然一个string的值不可能为null,我们通常使用的StringUtils.isNotEmpty中依然加了null值判断。 2.可以指出具体是哪段代码嘛。 If you have any question or suggestion, welcome to put forward~ Thx a lot~ ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected]
