ticdc: Refactor CheckIsTiDB
function to remove the returned error
#11505
Labels
area/ticdc
Issues or PRs related to TiCDC.
question
Further information is requested.
type/enhancement
The issue or PR belongs to an enhancement.
Before asking a question, make sure you have
What is your question?
Description:
In the
CheckIsTiDB
function, the current implementation returns anerror
which is no need for the external callers. In earlier versions, this function returned anerror
along with a boolean value, allowing callers to differentiate between network-related issues and the absence of TiDB. However, since the specific error content wasn't critical to the logic—external callers only needed to know whether the downstream was TiDB—the decision was made to simplify the function. External callers should not handle the error returned here because even if the downstream is not TiDB, TiCDC should still function properly. For more details, refer to #11214.The primary goal of this issue is to refactor the function to remove the error return type. Instead of returning an error, we will log a warning if an issue occurs while querying the TiDB version, as the error content itself is not critical to the logic. This change will simplify the function while maintaining awareness of potential network issues through logging.
Action Items:
CheckIsTiDB
.row.Scan()
fails.The text was updated successfully, but these errors were encountered: