Add select count(*) rather then analyze table which is used to get the total rows of the table for the jdbc-oracle in chunk split stage and oracle-cdc in full stage. Because sometimes the select count is faster than the analyze table. As shown in the figure below, direct select count takes 5 seconds to execute, but analyze table takes 1m37s.
Add the switch to skip analyze table. In some scenarios, for example, the user has a regular task to call analyze table to refresh the statistics of the relevant table, we can skip analyze table and directly query the total number of records of the corresponding table in the statistics, which is faster. And other case is that the table is updated infrequently.
Does this PR introduce any user-facing change?
How was this patch tested?
Check list
[ ] If any new Jar binary package adding in your PR, please add License Notice according
New License Guide
Purpose of this pull request
Does this PR introduce any user-facing change?
How was this patch tested?
Check list
release-note
.