Search in sources :

Example 1 with RocksDBPersistenceProvider

use of com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider in project iri by iotaledger.

the class BundleValidatorTest method setUp.

@BeforeClass
public static void setUp() throws Exception {
    TemporaryFolder dbFolder = new TemporaryFolder();
    TemporaryFolder logFolder = new TemporaryFolder();
    dbFolder.create();
    logFolder.create();
    tangle.addPersistenceProvider(new RocksDBPersistenceProvider(dbFolder.getRoot().getAbsolutePath(), logFolder.getRoot().getAbsolutePath(), 1000));
    tangle.init();
}
Also used : TemporaryFolder(org.junit.rules.TemporaryFolder) RocksDBPersistenceProvider(com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider) BeforeClass(org.junit.BeforeClass)

Example 2 with RocksDBPersistenceProvider

use of com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider in project iri by iotaledger.

the class BundleViewModelTest method setUp.

@Before
public void setUp() throws Exception {
    dbFolder.create();
    logFolder.create();
    RocksDBPersistenceProvider rocksDBPersistenceProvider;
    rocksDBPersistenceProvider = new RocksDBPersistenceProvider(dbFolder.getRoot().getAbsolutePath(), logFolder.getRoot().getAbsolutePath(), 1000);
    tangle.addPersistenceProvider(rocksDBPersistenceProvider);
    tangle.init();
}
Also used : RocksDBPersistenceProvider(com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider) Before(org.junit.Before)

Example 3 with RocksDBPersistenceProvider

use of com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider in project iri by iotaledger.

the class TransactionValidatorTest method setUp.

@BeforeClass
public static void setUp() throws Exception {
    dbFolder.create();
    logFolder.create();
    tangle = new Tangle();
    tangle.addPersistenceProvider(new RocksDBPersistenceProvider(dbFolder.getRoot().getAbsolutePath(), logFolder.getRoot().getAbsolutePath(), 1000));
    tangle.init();
    TipsViewModel tipsViewModel = new TipsViewModel();
    MessageQ messageQ = new MessageQ(0, "", 0, false);
    TransactionRequester txRequester = new TransactionRequester(tangle, messageQ);
    txValidator = new TransactionValidator(tangle, tipsViewModel, txRequester, messageQ);
    txValidator.init(false, MAINNET_MWM, TESTNET_MWM);
}
Also used : TransactionRequester(com.iota.iri.network.TransactionRequester) MessageQ(com.iota.iri.zmq.MessageQ) TipsViewModel(com.iota.iri.controllers.TipsViewModel) RocksDBPersistenceProvider(com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider) Tangle(com.iota.iri.storage.Tangle) BeforeClass(org.junit.BeforeClass)

Example 4 with RocksDBPersistenceProvider

use of com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider in project iri by iotaledger.

the class TangleTest method setUp.

@Before
public void setUp() throws Exception {
    TemporaryFolder dbFolder = new TemporaryFolder(), logFolder = new TemporaryFolder();
    dbFolder.create();
    logFolder.create();
    RocksDBPersistenceProvider rocksDBPersistenceProvider;
    rocksDBPersistenceProvider = new RocksDBPersistenceProvider(dbFolder.getRoot().getAbsolutePath(), logFolder.getRoot().getAbsolutePath(), 1000);
    tangle.addPersistenceProvider(rocksDBPersistenceProvider);
    tangle.init();
}
Also used : TemporaryFolder(org.junit.rules.TemporaryFolder) RocksDBPersistenceProvider(com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider) Before(org.junit.Before)

Example 5 with RocksDBPersistenceProvider

use of com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider in project iri by iotaledger.

the class TransactionViewModelTest method setUp.

@BeforeClass
public static void setUp() throws Exception {
    dbFolder.create();
    logFolder.create();
    RocksDBPersistenceProvider rocksDBPersistenceProvider;
    rocksDBPersistenceProvider = new RocksDBPersistenceProvider(dbFolder.getRoot().getAbsolutePath(), logFolder.getRoot().getAbsolutePath(), 1000);
    tangle.addPersistenceProvider(rocksDBPersistenceProvider);
    tangle.init();
}
Also used : RocksDBPersistenceProvider(com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider)

Aggregations

RocksDBPersistenceProvider (com.iota.iri.storage.rocksDB.RocksDBPersistenceProvider)8 BeforeClass (org.junit.BeforeClass)3 TipsViewModel (com.iota.iri.controllers.TipsViewModel)2 TransactionRequester (com.iota.iri.network.TransactionRequester)2 Tangle (com.iota.iri.storage.Tangle)2 MessageQ (com.iota.iri.zmq.MessageQ)2 Before (org.junit.Before)2 TemporaryFolder (org.junit.rules.TemporaryFolder)2 LedgerValidator (com.iota.iri.LedgerValidator)1 Milestone (com.iota.iri.Milestone)1 TransactionValidator (com.iota.iri.TransactionValidator)1 FileExportProvider (com.iota.iri.storage.FileExportProvider)1 ZmqPublishProvider (com.iota.iri.storage.ZmqPublishProvider)1 NotImplementedException (org.apache.commons.lang3.NotImplementedException)1