use of org.hyperledger.besu.chainimport.RlpBlockImporter in project besu by hyperledger.
the class Besu method main.
public static void main(final String... args) {
final Logger logger = setupLogging();
final BesuCommand besuCommand = new BesuCommand(logger, RlpBlockImporter::new, JsonBlockImporter::new, RlpBlockExporter::new, new RunnerBuilder(), new BesuController.Builder(), new BesuPluginContextImpl(), System.getenv());
besuCommand.parse(new RunLast().andExit(SUCCESS_EXIT_CODE), besuCommand.exceptionHandler().andExit(ERROR_EXIT_CODE), System.in, args);
}
use of org.hyperledger.besu.chainimport.RlpBlockImporter in project besu by hyperledger.
the class RlpBlockExporterTest method importBlocks.
private static Blockchain importBlocks(final BesuController controller, final Path blocksFile) throws IOException {
final RlpBlockImporter blockImporter = new RlpBlockImporter();
blockImporter.importBlockchain(blocksFile, controller, false);
return controller.getProtocolContext().getBlockchain();
}
Aggregations