This is an automated email from the ASF dual-hosted git repository.
tyrantlucifer pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-seatunnel.git
The following commit(s) were added to refs/heads/dev by this push:
new e486d5ca5 [Improve][Connector-V2] Update v2 config template (#3472)
e486d5ca5 is described below
commit e486d5ca5771d7ae4cb3bf4450ab6738c6364c20
Author: liugddx <[email protected]>
AuthorDate: Fri Nov 25 22:45:56 2022 +0800
[Improve][Connector-V2] Update v2 config template (#3472)
* Remove unnecessary code
* Update config/batch.conf.template
Co-authored-by: Tyrantlucifer <[email protected]>
* Update batch.conf.template
* fix cv error.
Co-authored-by: Tyrantlucifer <[email protected]>
---
config/flink.batch.conf.template | 55 ----------------------
...ming.conf.template => v2.batch.config.template} | 47 ++++++++++--------
...ng.conf.template => v2.streaming.conf.template} | 45 +++++++++++-------
3 files changed, 55 insertions(+), 92 deletions(-)
diff --git a/config/flink.batch.conf.template b/config/flink.batch.conf.template
deleted file mode 100644
index e1652c640..000000000
--- a/config/flink.batch.conf.template
+++ /dev/null
@@ -1,55 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######
-###### This config file is a demonstration of batch processing in SeaTunnel
config
-######
-
-env {
- # You can set flink configuration here
- execution.parallelism = 1
-}
-
-source {
- # This is a example input plugin **only for test and demonstrate the feature
input plugin**
-
- FakeSource {
- result_table_name = "test"
- field_name = "name,age"
- }
-
- # If you would like to get more information about how to configure seatunnel
and see full list of input plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/source-plugins/Fake
-}
-
-transform {
- Sql {
- sql = "select * from test"
- }
-
- # If you would like to get more information about how to configure seatunnel
and see full list of filter plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/transform-plugins/Sql
-}
-
-sink {
- # choose stdout output plugin to output data to console
- ConsoleSink {
- }
-
- # If you would like to get more information about how to configure seatunnel
and see full list of output plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/sink-plugins/Console
-}
diff --git a/config/flink.streaming.conf.template
b/config/v2.batch.config.template
similarity index 56%
copy from config/flink.streaming.conf.template
copy to config/v2.batch.config.template
index 8f233b144..425372b32 100644
--- a/config/flink.streaming.conf.template
+++ b/config/v2.batch.config.template
@@ -6,7 +6,7 @@
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
-# http://www.apache.org/licenses/LICENSE-2.0
+# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
@@ -14,41 +14,50 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
-
######
-###### This config file is a demonstration of streaming processing in
SeaTunnel config
+###### This config file is a demonstration of streaming processing in
Seatunnel config
######
env {
- # You can set flink configuration here
- execution.parallelism = 1
+ # You can set SeaTunnel environment configuration here
+ execution.parallelism = 2
+ job.mode = "BATCH"
#execution.checkpoint.interval = 10000
#execution.checkpoint.data-uri = "hdfs://localhost:9000/checkpoint"
}
source {
- # This is a example input plugin **only for test and demonstrate the feature
input plugin**
- FakeSourceStream {
- result_table_name = "fake"
- field_name = "name,age"
+ # This is a example source plugin **only for test and demonstrate the
feature source plugin**
+ FakeSource {
+ parallelism = 2
+ result_table_name = "fake"
+ row.num = 16
+ schema = {
+ fields {
+ name = "string"
+ age = "int"
+ }
}
+ }
- # If you would like to get more information about how to configure seatunnel
and see full list of input plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/source-plugins/Fake
+ # If you would like to get more information about how to configure Seatunnel
and see full list of source plugins,
+ # please go to https://seatunnel.apache.org/docs/category/source-v2
}
transform {
- sql {
- sql = "select name,age from fake"
- }
+ sql {
+ sql = "select name,age from fake"
+ }
- # If you would like to get more information about how to configure seatunnel
and see full list of filter plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/transform-plugins/Sql
+ # If you would like to get more information about how to configure Seatunnel
and see full list of transform plugins,
+ # please go to https://seatunnel.apache.org/docs/category/transform
}
sink {
- ConsoleSink {}
+ Console {
+ parallelism = 3
+ }
- # If you would like to get more information about how to configure seatunnel
and see full list of output plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/sink-plugins/Console
+ # If you would like to get more information about how to configure Seatunnel
and see full list of sink plugins,
+ # please go to https://seatunnel.apache.org/docs/category/sink-v2
}
diff --git a/config/flink.streaming.conf.template
b/config/v2.streaming.conf.template
similarity index 59%
rename from config/flink.streaming.conf.template
rename to config/v2.streaming.conf.template
index 8f233b144..80b943ab7 100644
--- a/config/flink.streaming.conf.template
+++ b/config/v2.streaming.conf.template
@@ -6,7 +6,7 @@
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
-# http://www.apache.org/licenses/LICENSE-2.0
+# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
@@ -14,41 +14,50 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
-
######
-###### This config file is a demonstration of streaming processing in
SeaTunnel config
+###### This config file is a demonstration of streaming processing in
Seatunnel config
######
env {
# You can set flink configuration here
- execution.parallelism = 1
+ execution.parallelism = 2
+ job.mode = "STREAMING"
#execution.checkpoint.interval = 10000
#execution.checkpoint.data-uri = "hdfs://localhost:9000/checkpoint"
}
source {
- # This is a example input plugin **only for test and demonstrate the feature
input plugin**
- FakeSourceStream {
- result_table_name = "fake"
- field_name = "name,age"
+ # This is a example source plugin **only for test and demonstrate the
feature source plugin**
+ FakeSource {
+ parallelism = 2
+ result_table_name = "fake"
+ row.num = 16
+ schema = {
+ fields {
+ name = "string"
+ age = "int"
+ }
}
+ }
- # If you would like to get more information about how to configure seatunnel
and see full list of input plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/source-plugins/Fake
+ # If you would like to get more information about how to configure Seatunnel
and see full list of source plugins,
+ # please go to https://seatunnel.apache.org/docs/category/source-v2
}
transform {
- sql {
- sql = "select name,age from fake"
- }
+ sql {
+ sql = "select name,age from fake"
+ }
- # If you would like to get more information about how to configure seatunnel
and see full list of filter plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/transform-plugins/Sql
+ # If you would like to get more information about how to configure Seatunnel
and see full list of transform plugins,
+ # please go to https://seatunnel.apache.org/docs/category/transform
}
sink {
- ConsoleSink {}
+ Console {
+ parallelism = 3
+ }
- # If you would like to get more information about how to configure seatunnel
and see full list of output plugins,
- # please go to
https://seatunnel.apache.org/docs/flink/configuration/sink-plugins/Console
+ # If you would like to get more information about how to configure Seatunnel
and see full list of sink plugins,
+ # please go to https://seatunnel.apache.org/docs/category/sink-v2
}