-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle export data status panics (#1874)
1. Handling nil pointer and the index out-of-range issues while running export data status before, during, and after export data. 2. Handled panics in `get data-migration report`, when it was run before export was started. 3. Fixed a bug in the `export data status` for partitions case from PG where we club the statuses of all leaf table to root tables's entry, which was not showing the progress of partitions and was just showing the NOT-STARTED for the entire duration of export data and was showing the DONE one it is completed. 4. Fixed the output of the export data status for the Debezium export case of PG partitions with table-list 5. Added expected files to be validated in pg-partitions automation test for table-list case of export-data-status command.
- Loading branch information
1 parent
c6a3b8a
commit 5320379
Showing
8 changed files
with
152 additions
and
52 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
37 changes: 37 additions & 0 deletions
37
migtests/tests/pg/partitions/export-data-status-report.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,37 @@ | ||
[ | ||
{ | ||
"table_name": "customers", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "sales", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "emp", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "p1.sales_region", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "range_columns_partition_test", | ||
"status": "DONE", | ||
"exported_count": 6 | ||
}, | ||
{ | ||
"table_name": "sales_region", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "test_partitions_sequences", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
} | ||
] |
37 changes: 37 additions & 0 deletions
37
migtests/tests/pg/partitions/export-data-status-with-table-list-report.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,37 @@ | ||
[ | ||
{ | ||
"table_name": "customers (cust_other, cust_part11, cust_part12, cust_part21, cust_part22)", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "sales (sales_2019_q4, sales_2020_q1, sales_2020_q2)", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "emp (emp_0, emp_1, emp_2)", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "p1.sales_region (p2.boston, p2.london, p2.sydney)", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "range_columns_partition_test (range_columns_partition_test_p0, range_columns_partition_test_p1)", | ||
"status": "DONE", | ||
"exported_count": 6 | ||
}, | ||
{ | ||
"table_name": "sales_region (boston, london, sydney)", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
}, | ||
{ | ||
"table_name": "test_partitions_sequences (test_partitions_sequences_b, test_partitions_sequences_l, test_partitions_sequences_s)", | ||
"status": "DONE", | ||
"exported_count": 1000 | ||
} | ||
] |
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
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
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