Unverified Commit d19cfe47 authored by Licho's avatar Licho Committed by GitHub

fix: flink 1.18 set operator not work and configure null error (#2764)

* fix: flink 1.18 set operator not work and configure null error Signed-off-by: 's avatarlicho <lecho.sun@gmail.com> * chore Signed-off-by: 's avatarlicho <lecho.sun@gmail.com> * Spotless Apply --------- Signed-off-by: 's avatarlicho <lecho.sun@gmail.com> Co-authored-by: 's avatarleechor <leechor@users.noreply.github.com>
parent 38019889
......@@ -74,7 +74,9 @@ public class TaskExtConfig implements Serializable {
@JsonIgnore
public Map<String, String> getCustomConfigMaps() {
return Asserts.isNotNullCollection(customConfig)
? customConfig.stream().collect(Collectors.toMap(ConfigItem::getKey, ConfigItem::getValue))
? customConfig.stream()
.filter(item -> item.getKey() != null && item.getValue() != null)
.collect(Collectors.toMap(ConfigItem::getKey, ConfigItem::getValue))
: new HashMap<>();
}
......
......@@ -23,6 +23,7 @@ import org.dinky.assertion.Asserts;
import org.dinky.data.model.LineageRel;
import org.dinky.data.result.SqlExplainResult;
import org.dinky.operations.CustomNewParserImpl;
import org.dinky.operations.DinkyExecutableOperation;
import org.dinky.trans.ddl.CustomSetOperation;
import org.dinky.utils.LineageContext;
......@@ -108,7 +109,8 @@ public class CustomTableEnvironmentImpl extends AbstractCustomTableEnvironment {
@Override
public boolean parseAndLoadConfiguration(String statement, Map<String, Object> setMap) {
List<Operation> operations = getParser().parse(statement);
for (Operation operation : operations) {
for (Operation outterOperation : operations) {
Operation operation = ((DinkyExecutableOperation) outterOperation).getInnerOperation();
if (operation instanceof SetOperation) {
callSet((SetOperation) operation, getStreamExecutionEnvironment(), setMap);
return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment