jluckie opened a new pull request, #13352: URL: https://github.com/apache/dolphinscheduler/pull/13352
Fix list param expand caught NPE, when sql has ?, it conflict with PARAM_REPLACE_CHAR (#13136) <!--Thanks very much for contributing to Apache DolphinScheduler. Please review https://dolphinscheduler.apache.org/en-us/community/development/pull-request.html before opening a pull request.--> ## Purpose of the pull request <!--(For example: This pull request adds checkstyle plugin).--> This pull request fix a bug (#13136) ## Brief change log <!--*(for example:)* - *Add maven-checkstyle-plugin to root pom.xml* --> 1. Change org.apache.dolphinscheduler.plugin.task.api.parser.ParameterUtils#expandListParameter 1.1. change param `formatSql` to `sql`,origin sql has more param info, not on `?`; 1.2. add param `rgex`, this constant has defined in SqlTask.java; 1.3. change `split("\\?")` to rgex, this is main purpose; 1.5. change `end with ?` to regex like `.+\\${xxx}$`; 2. Compatible with unit tests, org.apache.dolphinscheduler.plugin.task.api.parser.ParameterUtilsTest, Test OK. ## Verify this pull request <!--*(Please pick either of the following options)*--> This pull request is already covered by existing tests, such as *(please describe tests)*. org.apache.dolphinscheduler.plugin.task.api.parser.ParameterUtilsTest#expandListParameter -- 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]
