use of com.radixdlt.sync.MockedSyncServiceModule in project radixdlt by radixdlt.
the class FunctionalNodeModule method configure.
@Override
public void configure() {
install(new EventLoggerModule());
install(new DispatcherModule());
// Consensus
if (hasConsensus) {
install(new ConsensusModule());
if (hasEpochs) {
install(new EpochsConsensusModule());
} else {
install(new NoEpochsConsensusModule());
}
}
// Sync
if (hasLedger) {
if (!hasSync) {
install(mockedSyncServiceModule);
} else {
install(new SyncServiceModule());
if (hasEpochs) {
install(new EpochsSyncModule());
} else {
install(new NoEpochsSyncModule());
}
}
}
// State Manager
if (!hasLedger) {
install(new MockedLedgerModule());
} else {
install(new LedgerModule());
if (!hasMempool) {
install(new MockedCommandGeneratorModule());
if (!hasEpochs) {
install(new MockedStateComputerModule());
} else {
install(new MockedStateComputerWithEpochsModule());
}
} else {
install(new MempoolReceiverModule());
if (hasMempoolRelayer) {
install(new MempoolRelayerModule());
}
if (!hasRadixEngine) {
install(new MockedMempoolStateComputerModule());
} else {
install(new RadixEngineStateComputerModule());
install(new RadixEngineModule());
install(new RadixEngineCheckpointModule());
}
}
}
}
Aggregations