private boolean waitForStartScnInArchiveLogs(ChangeEventSourceContext context, Scn startScn)
            throws SQLException, InterruptedException {
        boolean showStartScnNotInArchiveLogs = true;
        while (context.isRunning() && !isStartScnInArchiveLogs(startScn)) {
            if (showStartScnNotInArchiveLogs) {
                LOGGER.warn(
                        "Starting SCN {} is not yet in archive logs, waiting for archive log switch.",
                        startScn);
                showStartScnNotInArchiveLogs = false;
                Metronome.sleeper(connectorConfig.getArchiveLogOnlyScnPollTime(), clock).pause();
            }
        }

        if (!context.isRunning()) {
            return false;
        }

        if (!showStartScnNotInArchiveLogs) {
            LOGGER.info(
                    "Starting SCN {} is now available in archive logs, log mining unpaused.",
                    startScn);
        }
        return true;
    }
Waits for the starting system change number to exist in the archive logs before returning.

@param context the change event source context
@param startScn the starting system change number
@return true if the code should continue, false if the code should end.
@throws SQLException if a database exception occurred
@throws InterruptedException if the pause between checks is interrupted
inlong-sort/sort-flink/sort-flink-v1.13/sort-connectors/oracle-cdc/src/main/java/io/debezium/connector/oracle/logminer/LogMinerStreamingChangeEventSource.java