-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into e2e_bigquerymultitable
- Loading branch information
Showing
15 changed files
with
941 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
454 changes: 454 additions & 0 deletions
454
src/e2e-test/features/bigquery/sink/BigQueryToBigQueryAdditional.feature
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
256 changes: 256 additions & 0 deletions
256
src/e2e-test/java/io/cdap/plugin/common/stepsdesign/TestSetupHooks.java
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{"Firstname":"singh","ID":"Gurgaon","transaction_date":"2021-02-22","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} | ||
{"Firstname":"Neera","ID":"Agra","transaction_date":"2021-02-20","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} | ||
{"Firstname":"","ID":"Noida","transaction_date":"2021-02-21","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{"Firstname":"singh","ID":"Gurgaon","transaction_date":"2021-02-22","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} | ||
{"Firstname":"Neera","ID":"Agra","transaction_date":"2021-02-20","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} | ||
{"Firstname":"","ID":"Noida","transaction_date":"2021-02-21","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} |
2 changes: 2 additions & 0 deletions
2
src/e2e-test/resources/testdata/BigQuery/BQDifferentRecordNameFile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{"ID":1,"Name":"string_1","Price":0.1} | ||
{"ID":1,"Name":"string_1","Price":0.1} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{"Customer_Exists":true,"ID":3,"Name":"Rajan Kumar","Price":100.0} | ||
{"Customer_Exists":true,"ID":3,"Name":"Rajan Kumar","Price":100.0} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{"Firstname":"singh","ID":"Gurgaon","transaction_date":"2021-02-22","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} | ||
{"Firstname":"Neera","ID":"Agra","transaction_date":"2021-02-20","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} | ||
{"Firstname":"","ID":"Noida","transaction_date":"2021-02-21","transaction_dt":"2019-07-07T11:24:00","updated_on":"2019-03-10T04:50:01Z"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{"Customer_Exists":true,"ID":0,"Name":"string_0","Price":0.0} | ||
{"Customer_Exists":true,"ID":1,"Name":"string_1","Price":0.1} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{"Customer_Exists":false,"ID":3,"Name":"string_3","Price":0.3} | ||
{"Customer_Exists":false,"ID":2,"Name":"string_1","Price":0.2} | ||
{"Customer_Exists":true,"ID":0,"Name":"string_0","Price":0.0} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{"Customer_Exists":true,"ID":5,"Name":"Raja","Price":500.0} | ||
{"Customer_Exists":false,"ID":6,"Name":"Tom","Price":100.0} |
183 changes: 183 additions & 0 deletions
183
src/e2e-test/resources/testdata/BigQuery/test_diffschema_record-cdap-data-pipeline.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,183 @@ | ||
{ | ||
"name": "test_diffschema_record", | ||
"description": "Data Pipeline Application", | ||
"artifact": { | ||
"name": "cdap-data-pipeline", | ||
"version": "6.10.0-SNAPSHOT", | ||
"scope": "SYSTEM" | ||
}, | ||
"config": { | ||
"resources": { | ||
"memoryMB": 2048, | ||
"virtualCores": 1 | ||
}, | ||
"driverResources": { | ||
"memoryMB": 2048, | ||
"virtualCores": 1 | ||
}, | ||
"connections": [ | ||
{ | ||
"from": "BigQuery", | ||
"to": "Wrangler" | ||
}, | ||
{ | ||
"from": "Wrangler", | ||
"to": "BigQuery3" | ||
}, | ||
{ | ||
"from": "BigQuery2", | ||
"to": "BigQuery3" | ||
} | ||
], | ||
"comments": [], | ||
"postActions": [], | ||
"properties": {}, | ||
"processTimingEnabled": true, | ||
"stageLoggingEnabled": false, | ||
"stages": [ | ||
{ | ||
"name": "BigQuery", | ||
"plugin": { | ||
"name": "BigQueryTable", | ||
"type": "batchsource", | ||
"label": "BigQuery", | ||
"artifact": { | ||
"name": "google-cloud", | ||
"version": "0.22.0-SNAPSHOT", | ||
"scope": "SYSTEM" | ||
}, | ||
"properties": { | ||
"useConnection": "false", | ||
"project": "cdf-athena", | ||
"serviceAccountType": "filePath", | ||
"serviceFilePath": "auto-detect", | ||
"referenceName": "bq_ref", | ||
"dataset": "bq_automation", | ||
"table": "bqSourceTableMore", | ||
"enableQueryingViews": "false", | ||
"schema": "{\"type\":\"record\",\"name\":\"output\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]},{\"name\":\"TableName\",\"type\":[\"string\",\"null\"]}]}" | ||
} | ||
}, | ||
"outputSchema": "{\"type\":\"record\",\"name\":\"output\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]},{\"name\":\"TableName\",\"type\":[\"string\",\"null\"]}]}", | ||
"id": "BigQuery", | ||
"type": "batchsource", | ||
"label": "BigQuery", | ||
"icon": "fa-plug" | ||
}, | ||
{ | ||
"name": "Wrangler", | ||
"plugin": { | ||
"name": "Wrangler", | ||
"type": "transform", | ||
"label": "Wrangler", | ||
"artifact": { | ||
"name": "wrangler-transform", | ||
"version": "4.10.0-SNAPSHOT", | ||
"scope": "SYSTEM" | ||
}, | ||
"properties": { | ||
"field": "*", | ||
"precondition": "false", | ||
"directives": "drop :TableName", | ||
"on-error": "fail-pipeline", | ||
"schema": "{\"type\":\"record\",\"name\":\"record\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}", | ||
"workspaceId": "7038fc39-732e-4d75-8d3f-db6cfe5a11d8" | ||
} | ||
}, | ||
"outputSchema": "{\"type\":\"record\",\"name\":\"record\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}", | ||
"inputSchema": [ | ||
{ | ||
"name": "BigQuery", | ||
"schema": "{\"type\":\"record\",\"name\":\"output\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]},{\"name\":\"TableName\",\"type\":[\"string\",\"null\"]}]}" | ||
} | ||
], | ||
"id": "Wrangler", | ||
"type": "transform", | ||
"label": "Wrangler", | ||
"icon": "icon-DataPreparation" | ||
}, | ||
{ | ||
"name": "BigQuery3", | ||
"plugin": { | ||
"name": "BigQueryTable", | ||
"type": "batchsink", | ||
"label": "BigQuery3", | ||
"artifact": { | ||
"name": "google-cloud", | ||
"version": "0.22.0-SNAPSHOT", | ||
"scope": "SYSTEM" | ||
}, | ||
"properties": { | ||
"useConnection": "false", | ||
"project": "auto-detect", | ||
"serviceAccountType": "filePath", | ||
"serviceFilePath": "auto-detect", | ||
"dataset": "bq_automation", | ||
"table": "New_target_table_combine", | ||
"operation": "insert", | ||
"truncateTable": "false", | ||
"allowSchemaRelaxation": "false", | ||
"location": "US", | ||
"createPartitionedTable": "false", | ||
"partitioningType": "TIME", | ||
"partitionFilterRequired": "false", | ||
"schema": "{\"type\":\"record\",\"name\":\"record\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}" | ||
} | ||
}, | ||
"outputSchema": "{\"type\":\"record\",\"name\":\"record\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}", | ||
"inputSchema": [ | ||
{ | ||
"name": "Wrangler", | ||
"schema": "{\"type\":\"record\",\"name\":\"record\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}" | ||
}, | ||
{ | ||
"name": "BigQuery2", | ||
"schema": "{\"type\":\"record\",\"name\":\"output\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}" | ||
} | ||
], | ||
"id": "BigQuery3", | ||
"type": "batchsink", | ||
"label": "BigQuery3", | ||
"icon": "fa-plug" | ||
}, | ||
{ | ||
"name": "BigQuery2", | ||
"plugin": { | ||
"name": "BigQueryTable", | ||
"type": "batchsource", | ||
"label": "BigQuery2", | ||
"artifact": { | ||
"name": "google-cloud", | ||
"version": "0.22.0-SNAPSHOT", | ||
"scope": "SYSTEM" | ||
}, | ||
"properties": { | ||
"useConnection": "false", | ||
"project": "cdf-athena", | ||
"serviceAccountType": "filePath", | ||
"serviceFilePath": "auto-detect", | ||
"referenceName": "bq_test", | ||
"dataset": "bq_automation", | ||
"table": "bqSourceTableLess", | ||
"enableQueryingViews": "false", | ||
"schema": "{\"type\":\"record\",\"name\":\"output\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}" | ||
} | ||
}, | ||
"outputSchema": "{\"type\":\"record\",\"name\":\"output\",\"fields\":[{\"name\":\"ID\",\"type\":[\"long\",\"null\"]},{\"name\":\"Name\",\"type\":[\"string\",\"null\"]},{\"name\":\"Price\",\"type\":[\"double\",\"null\"]}]}", | ||
"id": "BigQuery2", | ||
"type": "batchsource", | ||
"label": "BigQuery2", | ||
"icon": "fa-plug" | ||
} | ||
], | ||
"schedule": "0 1 */1 * *", | ||
"engine": "spark", | ||
"numOfRecordsPreview": 100, | ||
"rangeRecordsPreview": { | ||
"min": 1, | ||
"max": "5000" | ||
}, | ||
"maxConcurrentRuns": 1 | ||
}, | ||
"version": "fe4ee1e3-6380-11ee-8217-0000003390c8" | ||
} |