Browse Source

1. specified jackson Date format.

2. remove getMapper method,replace with toList()
3. rewrite toList method,support constructCollectionType.
4. parseObject(resp, Map.class) replace to toMap() method
5. rename JacksonSerialize to JsonSerializer

rewrite createArrayNode,createObjectNode method will Affect too many lines ,i will fix it in the next pr.
pull/2/head
simon824 4 years ago
parent
commit
8cabb7a907
  1. 4
      dolphinscheduler-common/src/main/java/org/apache/dolphinscheduler/common/utils/JSONUtils.java
  2. 1
      dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/worker/task/datax/DataxTask.java

4
dolphinscheduler-common/src/main/java/org/apache/dolphinscheduler/common/utils/JSONUtils.java

@ -187,7 +187,7 @@ public class JSONUtils {
*/
public static Map<String, String> toMap(String json) {
if (StringUtils.isEmpty(json)) {
return new HashMap<>();
return null;
}
try {
@ -196,7 +196,7 @@ public class JSONUtils {
logger.error("json to map exception!", e);
}
return new HashMap<>();
return null;
}
/**

1
dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/worker/task/datax/DataxTask.java

@ -277,7 +277,6 @@ public class DataxTask extends AbstractTask {
dataSourceCfg, dataXParameters.getSql());
ArrayNode columnArr = writerParam.putArray("column");
columnArr.addAll()
for (String column : columns) {
columnArr.add(column);
}

Loading…
Cancel
Save