You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by "kim-up (via GitHub)" <gi...@apache.org> on 2023/04/14 10:47:26 UTC
[GitHub] [incubator-seatunnel] kim-up opened a new pull request, #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector #4577
kim-up opened a new pull request, #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578
#4577
<!--
Thank you for contributing to SeaTunnel! Please make sure that your code changes
are covered with tests. And in case of new features or big changes
remember to adjust the documentation.
Feel free to ping committers for the review!
## Contribution Checklist
- Make sure that the pull request corresponds to a [GITHUB issue](https://github.com/apache/incubator-seatunnel/issues).
- Name the pull request in the form "[Feature] [component] Title of the pull request", where *Feature* can be replaced by `Hotfix`, `Bug`, etc.
- Minor fixes should be named following this pattern: `[hotfix] [docs] Fix typo in README.md doc`.
-->
## Purpose of this pull request
<!-- Describe the purpose of this pull request. For example: This pull request adds checkstyle plugin.-->
## Check list
* [x] Code changed are covered with tests, or it does not need tests for reason:
* [x] If any new Jar binary package adding in your PR, please add License Notice according
[New License Guide](https://github.com/apache/incubator-seatunnel/blob/dev/docs/en/contribution/new-license.md)
* [x] If necessary, please update the documentation to describe the new feature. https://github.com/apache/incubator-seatunnel/tree/dev/docs
* [x] If you are contributing the connector code, please check that the following files are updated:
1. Update change log that in connector document. For more details you can refer to [connector-v2](https://github.com/apache/incubator-seatunnel/tree/dev/docs/en/connector-v2)
2. Update [plugin-mapping.properties](https://github.com/apache/incubator-seatunnel/blob/dev/plugin-mapping.properties) and add new connector information in it
3. Update the pom file of [seatunnel-dist](https://github.com/apache/incubator-seatunnel/blob/dev/seatunnel-dist/pom.xml)
* [x] Update the [`release-note`](https://github.com/apache/incubator-seatunnel/blob/dev/release-note.md).
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [seatunnel] ic4y commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "ic4y (via GitHub)" <gi...@apache.org>.
ic4y commented on PR #4578:
URL: https://github.com/apache/seatunnel/pull/4578#issuecomment-1666846947
@kim-up Please use mvn spotless:apply to format the code.
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522912623
@TyrantLucifer Did you mean the test screenshot provided above?
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/seatunnel/pull/4578#issuecomment-1669317481
> @kim-up Please use mvn spotless:apply to format the code.
Done. Fixed by merging `dev` .
![image](https://github.com/apache/seatunnel/assets/9264192/52a087b7-e27e-48bd-ad16-a1bf7dde8261)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1518493778
@TyrantLucifer @hailin0 @EricJoy2048 @jbonofre Asking for Help!. Are there any end-to-end test examples for file storage cloud services such as obs, oss, and s3? Because it involves sensitive information such as ak and sk. And cloud services do not necessarily have relevant docker images that can be used for Mock testing.
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1515687816
@TyrantLucifer @EricJoy2048 @hailin0 Is there anything else I need to do ?
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] TyrantLucifer commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "TyrantLucifer (via GitHub)" <gi...@apache.org>.
TyrantLucifer commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1510999113
> ![image](https://user-images.githubusercontent.com/9264192/232371858-da3f5c79-d514-4908-9982-2bb6f4b4bd1b.png)
>
> The dependency of `esdk-obs-java` can not download. https://mvnrepository.com/artifact/com.huawei.storage/esdk-obs-java/3.19.7.3 ![image](https://user-images.githubusercontent.com/9264192/232372168-51c92713-277e-4746-b83c-b4f6b3912ccc.png)
>
> @TyrantLucifer How should this be handled?
You can find solution in `oss-jindo` module's pom file.
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] hailin0 commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "hailin0 (via GitHub)" <gi...@apache.org>.
hailin0 commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1511675898
Please add e2e testcase and make junit @Disabled
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522873829
## Local Test Images
### Json Test
#### fake_to_obs_file_json
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
FakeSource {
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
result_table_name = "fake"
}
}
sink {
ObsFile {
path = "/seatunnel/json"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
row_delimiter = "\n"
partition_dir_expression = "${k0}=${v0}"
is_partition_field_write_in_file = true
file_name_expression = "${transactionId}_${now}"
file_format_type = "json"
filename_time_format = "yyyy.MM.dd"
is_enable_transaction = true
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234491535-229e4214-56e2-41d5-9d86-23312fc3b6ce.png)
![image](https://user-images.githubusercontent.com/9264192/234491607-2fcb8e5d-3e0a-44c3-91d3-0e3406aa5b74.png)
### obs_file_json_to_assert
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
ObsFile {
path = "/seatunnel/json"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
file_format_type = "json"
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
result_table_name = "fake"
}
}
sink {
Assert {
rules {
row_rules = [
{
rule_type = MAX_ROW
rule_value = 5
}
],
field_rules = [
{
field_name = c_string
field_type = string
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_boolean
field_type = boolean
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_double
field_type = double
field_value = [
{
rule_type = NOT_NULL
}
]
}
]
}
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234491844-81b66343-3802-471d-8595-1d48e7a92bbc.png)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] TyrantLucifer commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "TyrantLucifer (via GitHub)" <gi...@apache.org>.
TyrantLucifer commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1518532528
>
Hi @kim-up , you can add a e2e test case and run it in your local env, before submit codes you should add annotation to disabled it and remove sensitive information from config file. Finally offer the snapshot image in this pull request. You can refer to `selectdb-e2e` and `file-local-e2e`. The idea is to allow novices to quickly find test cases for the connector and run through the code framework you provide by directly changing some key information
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522904658
## Local Test Images
### Text Test
#### fake_to_obs_file_text
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
FakeSource {
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
result_table_name = "fake"
}
}
sink {
ObsFile {
path = "/seatunnel/text"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
row_delimiter = "\n"
partition_dir_expression = "${k0}=${v0}"
is_partition_field_write_in_file = true
file_name_expression = "${transactionId}_${now}"
file_format_type = "text"
filename_time_format = "yyyy.MM.dd"
is_enable_transaction = true
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234497989-2c24633e-fc88-4fa6-ac54-873e095b8c5c.png)
![image](https://user-images.githubusercontent.com/9264192/234497898-3a4f8740-8f73-4a9b-bda7-ef1b2fbcb3b7.png)
### obs_file_text_projection_to_assert
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
ObsFile {
path = "/seatunnel/text"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
file_format_type = "text"
read_columns = [c_string, c_boolean, c_double]
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
result_table_name = "fake"
}
}
sink {
Assert {
rules {
row_rules = [
{
rule_type = MAX_ROW
rule_value = 5
}
],
field_rules = [
{
field_name = c_string
field_type = string
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_boolean
field_type = boolean
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_double
field_type = double
field_value = [
{
rule_type = NOT_NULL
}
]
}
]
}
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234498493-0e9aa21d-a7b1-4fe3-a6ef-9c3e37c73549.png)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1519668398
Docs & e2e have add. Start the workflow? @TyrantLucifer @EricJoy2048 @hailin0
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] TyrantLucifer commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector #4577
Posted by "TyrantLucifer (via GitHub)" <gi...@apache.org>.
TyrantLucifer commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1508321953
Good pull request, let's waiting CI
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522879906
## Local Test Images
### Orc Test
#### fake_to_obs_file_orc
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
FakeSource {
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
result_table_name = "fake"
}
}
sink {
ObsFile {
path = "/seatunnel/orc"
bucket = "obs://*******"
access_key = "*******"
access_secret = "*******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
row_delimiter = "\n"
partition_dir_expression = "${k0}=${v0}"
is_partition_field_write_in_file = true
file_name_expression = "${transactionId}_${now}"
file_format_type = "orc"
filename_time_format = "yyyy.MM.dd"
is_enable_transaction = true
compress_codec = "zlib"
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234492856-d6f6fdbb-3e80-4f16-a13c-c467e748d9ae.png)
![image](https://user-images.githubusercontent.com/9264192/234492995-ac0d3c49-fb25-4f41-9358-d26ee5ffb6ee.png)
### obs_file_orc_projection_to_assert
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
ObsFile {
path = "/seatunnel/orc"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
file_format_type = "orc"
read_columns = [c_string, c_boolean, c_double]
result_table_name = "fake"
}
}
sink {
Assert {
rules {
row_rules = [
{
rule_type = MAX_ROW
rule_value = 5
}
],
field_rules = [
{
field_name = c_string
field_type = string
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_boolean
field_type = boolean
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_double
field_type = double
field_value = [
{
rule_type = NOT_NULL
}
]
}
]
}
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234493570-2bedf087-918b-4575-9ccc-f1ae8a90468c.png)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522867377
## Local Test Images
### Excel Test
#### fake_to_obs_excel
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
FakeSource {
result_table_name = "fake"
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
}
}
sink {
ObsFile {
path="/seatunnel/excel"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
partition_dir_expression="${k0}=${v0}"
is_partition_field_write_in_file=true
file_name_expression="${transactionId}_${now}"
file_format_type="excel"
filename_time_format="yyyy.MM.dd"
is_enable_transaction=true
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234489243-e5baafd5-c2d2-4a6f-b459-256b774b3f44.png)
![image](https://user-images.githubusercontent.com/9264192/234489386-0005494a-5801-4104-ba38-f66df7de2eae.png)
### obs_excel_projection_to_assert
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
ObsFile {
path="/seatunnel/excel"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
result_table_name = "fake"
file_format_type = excel
delimiter = ;
read_columns = [c_string, c_boolean]
skip_header_row_number = 1
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
}
}
sink {
Assert {
rules {
row_rules = [
{
rule_type = MAX_ROW
rule_value = 5
}
],
field_rules = [
{
field_name = c_string
field_type = string
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_boolean
field_type = boolean
field_value = [
{
rule_type = NOT_NULL
}
]
}
]
}
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234490558-1ea3ceb6-7166-422c-aa36-ff014cf16a38.png)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1518985340
> >
>
> Hi @kim-up , you can add a e2e test case and run it in your local env, before submit codes you should add annotation to disabled it and remove sensitive information from config file. Finally offer the snapshot image in this pull request. You can refer to `selectdb-e2e` and `file-local-e2e`. The idea is to allow novices to quickly find test cases for the connector and run through the code framework you provide by directly changing some key information
Get it.
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522889475
## Local Test Images
### Parquet Test
#### fake_to_obs_file_parquet
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
FakeSource {
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
result_table_name = "fake"
}
}
sink {
ObsFile {
path = "/seatunnel/parquet"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
row_delimiter = "\n"
partition_dir_expression = "${k0}=${v0}"
is_partition_field_write_in_file = true
file_name_expression = "${transactionId}_${now}"
file_format_type = "parquet"
filename_time_format = "yyyy.MM.dd"
is_enable_transaction = true
compress_codec = "gzip"
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234495054-fbb9d35e-eb9a-4332-929c-38104753e137.png)
![image](https://user-images.githubusercontent.com/9264192/234495108-96579c86-ef90-4c2a-8d75-9c9f42841704.png)
### obs_file_parquet_projection_to_assert
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
ObsFile {
path = "/seatunnel/parquet"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
file_format_type = "parquet"
read_columns = [c_string, c_boolean, c_double]
result_table_name = "fake"
}
}
sink {
Assert {
rules {
row_rules = [
{
rule_type = MAX_ROW
rule_value = 5
}
],
field_rules = [
{
field_name = c_string
field_type = string
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_boolean
field_type = boolean
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_double
field_type = double
field_value = [
{
rule_type = NOT_NULL
}
]
}
]
}
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234495441-5c812b6f-aed5-4641-b82e-45a7051d303b.png)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1522856229
## Local Test Images
### Csv Test
#### fake_to_obs_csv
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
FakeSource {
result_table_name = "fake"
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
}
}
sink {
ObsFile {
path="/seatunnel/csv"
bucket = "obs://********"
access_key = "********"
access_secret = "********"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
partition_dir_expression="${k0}=${v0}"
is_partition_field_write_in_file=true
file_name_expression="${transactionId}_${now}"
file_format_type="csv"
filename_time_format="yyyy.MM.dd"
is_enable_transaction=true
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234486062-f9eb0b64-9bdb-4787-a206-63333bec8e52.png)
![image](https://user-images.githubusercontent.com/9264192/234486184-bd4e1627-40b7-48b7-9ab7-80736a036e99.png)
### fake_to_obs_csv
```
env {
execution.parallelism = 1
checkpoint.interval = 5000
job.mode = "BATCH"
}
source {
ObsFile {
path="/seatunnel/csv"
bucket = "obs://******"
access_key = "******"
access_secret = "******"
endpoint = "obs.cn-east-3.myhuaweicloud.com"
result_table_name = "fake"
file_format_type = csv
delimiter = ","
read_columns = [c_string, c_boolean]
skip_header_row_number = 1
schema = {
fields {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
c_row = {
c_map = "map<string, string>"
c_array = "array<int>"
c_string = string
c_boolean = boolean
c_tinyint = tinyint
c_smallint = smallint
c_int = int
c_bigint = bigint
c_float = float
c_double = double
c_bytes = bytes
c_date = date
c_decimal = "decimal(38, 18)"
c_timestamp = timestamp
}
}
}
}
}
sink {
Assert {
rules {
row_rules = [
{
rule_type = MAX_ROW
rule_value = 5
}
],
field_rules = [
{
field_name = c_string
field_type = string
field_value = [
{
rule_type = NOT_NULL
}
]
},
{
field_name = c_boolean
field_type = boolean
field_value = [
{
rule_type = NOT_NULL
}
]
}
]
}
}
}
```
##### Result
![image](https://user-images.githubusercontent.com/9264192/234487843-96c8a451-8925-43d6-b86f-07d1e86f4f3e.png)
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] EricJoy2048 commented on a diff in pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "EricJoy2048 (via GitHub)" <gi...@apache.org>.
EricJoy2048 commented on code in PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#discussion_r1168424674
##########
docs/en/connector-v2/sink/ObsFile.md:
##########
@@ -0,0 +1,260 @@
+# ObsFile
Review Comment:
After discussion in the community, we have optimized the format requirements of the document, which you can refer to:`https://github.com/apache/incubator-seatunnel/issues/4544`
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on a diff in pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on code in PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#discussion_r1168440436
##########
docs/en/connector-v2/sink/ObsFile.md:
##########
@@ -0,0 +1,260 @@
+# ObsFile
Review Comment:
Ok
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1510657374
![image](https://user-images.githubusercontent.com/9264192/232371858-da3f5c79-d514-4908-9982-2bb6f4b4bd1b.png)
The dependency of `esdk-obs-java` can not download.
https://mvnrepository.com/artifact/com.huawei.storage/esdk-obs-java/3.19.7.3
![image](https://user-images.githubusercontent.com/9264192/232372168-51c92713-277e-4746-b83c-b4f6b3912ccc.png)
@TyrantLucifer How should this be handled?
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] kim-up commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "kim-up (via GitHub)" <gi...@apache.org>.
kim-up commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1521130699
> > Docs & e2e have add. Start the workflow? @TyrantLucifer @EricJoy2048 @hailin0
>
> Approved, let's waiting CI/CD, BTW could you please offer some snapshots of this connector?
What is `some snapshots` ? Docker image ? Is there any related document that can refer to...
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] TyrantLucifer commented on pull request #4578: [Feature][Connector-V2] Add Huawei Cloud OBS connector
Posted by "TyrantLucifer (via GitHub)" <gi...@apache.org>.
TyrantLucifer commented on PR #4578:
URL: https://github.com/apache/incubator-seatunnel/pull/4578#issuecomment-1520340010
> Docs & e2e have add. Start the workflow? @TyrantLucifer @EricJoy2048 @hailin0
Approved, let's waiting CI/CD, BTW could you please offer some snapshots of this connector?
--
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: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org