예제 #1
0
 public static void Startup()
 {
     // Folder has to be there or the config fails.
     TestAssetLocalStorageLmdbPartitionedLRUCtor.RebuildLocalStorageFolder(TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_FOLDER_PATH, WRITE_CACHE_FILE_PATH);
     _chattelConfigRead  = new ChattelConfiguration(TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_FOLDER_PATH, WRITE_CACHE_FILE_PATH, WRITE_CACHE_MAX_RECORD_COUNT, (IAssetServer)null);
     _chattelConfigWrite = new ChattelConfiguration(TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_FOLDER_PATH, WRITE_CACHE_FILE_PATH, WRITE_CACHE_MAX_RECORD_COUNT, (IAssetServer)null);
 }
        public static void BeforeEveryTest()
        {
            TestAssetLocalStorageLmdbPartitionedLRUCtor.RebuildLocalStorageFolder(DATABASE_FOLDER_PATH, TestStorageManager.WRITE_CACHE_FILE_PATH);

            _localStorage = _localStorageLmdb = new AssetLocalStorageLmdbPartitionedLRU(
                _chattelConfigRead,
                DATABASE_MAX_SIZE_BYTES,
                TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_PARTITION_INTERVAL
                );
        }
예제 #3
0
        public static void BeforeEveryTest()
        {
            LOG.Info($"Executing {nameof(BeforeEveryTest)}");
            TestAssetLocalStorageLmdbPartitionedLRUCtor.RebuildLocalStorageFolder(TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_FOLDER_PATH, WRITE_CACHE_FILE_PATH);

            _readerLocalStorage = new AssetLocalStorageLmdbPartitionedLRU(
                _chattelConfigRead,
                TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_MAX_SIZE_BYTES,
                TestAssetLocalStorageLmdbPartitionedLRUCtor.DATABASE_PARTITION_INTERVAL
                );
            _chattelReader = new ChattelReader(_chattelConfigRead, _readerLocalStorage);
            _chattelWriter = new ChattelWriter(_chattelConfigWrite, _readerLocalStorage);
        }
 public static void Startup()
 {
     // Folder has to be there or the config fails.
     TestAssetLocalStorageLmdbPartitionedLRUCtor.RebuildLocalStorageFolder(DATABASE_FOLDER_PATH, TestStorageManager.WRITE_CACHE_FILE_PATH);
     _chattelConfigRead = new ChattelConfiguration(DATABASE_FOLDER_PATH);
 }