diff --git a/piflow-bundle/src/main/resources/flow.json b/piflow-bundle/src/main/resources/flow.json index 3b88e2f..62345c6 100644 --- a/piflow-bundle/src/main/resources/flow.json +++ b/piflow-bundle/src/main/resources/flow.json @@ -47,6 +47,22 @@ "name":"Merge", "bundle":"cn.piflow.bundle.common.Merge", "properties":{} + }, + { + "uuid":"666", + "name":"Fork", + "bundle":"cn.piflow.bundle.common.Fork", + "properties":{ + "outports":["out1","out2"] + } + }, + { + "uuid":"777", + "name":"JsonSave", + "bundle":"cn.piflow.bundle.json.JsonSave", + "properties":{ + "jsonSavePath":"hdfs://10.0.86.89:9000/xjzhu/phdthesis.json" + } } ], "paths":[ @@ -72,7 +88,19 @@ "from":"Merge", "outport":"", "inport":"", + "to":"Fork" + }, + { + "from":"Fork", + "outport":"out1", + "inport":"", "to":"PutHiveStreaming" + }, + { + "from":"Fork", + "outport":"out2", + "inport":"", + "to":"JsonSave" } ] } diff --git a/piflow-bundle/src/main/scala/cn/piflow/bundle/common/SelectField.scala b/piflow-bundle/src/main/scala/cn/piflow/bundle/common/SelectField.scala index 19fa259..380d7f7 100644 --- a/piflow-bundle/src/main/scala/cn/piflow/bundle/common/SelectField.scala +++ b/piflow-bundle/src/main/scala/cn/piflow/bundle/common/SelectField.scala @@ -11,7 +11,7 @@ import scala.beans.BeanProperty class SelectField extends ConfigurableStop { - val inportCount: Int = -1 + val inportCount: Int = 1 val outportCount: Int = 1 var schema:String = _ diff --git a/piflow-bundle/src/main/scala/cn/piflow/bundle/csv/CsvParser.scala b/piflow-bundle/src/main/scala/cn/piflow/bundle/csv/CsvParser.scala index c220176..42dbdd2 100644 --- a/piflow-bundle/src/main/scala/cn/piflow/bundle/csv/CsvParser.scala +++ b/piflow-bundle/src/main/scala/cn/piflow/bundle/csv/CsvParser.scala @@ -12,7 +12,7 @@ import scala.beans.BeanProperty class CsvParser extends ConfigurableStop{ - val inportCount: Int = 1 + val inportCount: Int = 0 val outportCount: Int = 1 var csvPath: String = _