protected synchronized void recoverRecords(Consumer<HistoryRecord> records) {
        this.lock.write(() -> {
            try {
                if (this.exists()) {
                    Iterator var2 = Files.readAllLines(this.path, UTF8).iterator();

                    while (var2.hasNext()) {
                        String line = (String) var2.next();
                        if (line != null && !line.isEmpty()) {
                            records.accept(new HistoryRecord(this.reader.read(line)));
                        }
                    }
                }
            } catch (IOException var4) {
                this.logger.error("Failed to add recover records from history at {}", this.path, var4);
            }

        });
        this.schemaRecords.stream().map(SchemaRecord::getHistoryRecord).forEach(records);
    }
A {@link DatabaseHistory} implementation that stores the schema history in a local file.
inlong-agent/agent-plugins/src/main/java/org/apache/inlong/agent/plugin/utils/InLongDatabaseHistory.java