use of org.voltdb.SimpleFileSnapshotDataTarget in project voltdb by VoltDB.
the class CSVSnapshotWritePlan method createDataTargetForTable.
private SnapshotDataTarget createDataTargetForTable(String file_path, String file_nonce, int hostId, AtomicInteger numTables, SnapshotRegistry.Snapshot snapshotRecord, Table table) throws IOException {
SnapshotDataTarget sdt;
File saveFilePath = SnapshotUtil.constructFileForTable(table, file_path, file_nonce, SnapshotFormat.CSV, hostId);
sdt = new SimpleFileSnapshotDataTarget(saveFilePath, !table.getIsreplicated());
m_targets.add(sdt);
final Runnable onClose = new TargetStatsClosure(sdt, table.getTypeName(), numTables, snapshotRecord);
sdt.setOnCloseHandler(onClose);
return sdt;
}
Aggregations