コード例 #1
0
ファイル: LockTests.cs プロジェクト: rustedwizard/FASTER
 public void Setup()
 {
     log = Devices.CreateLogDevice(TestContext.CurrentContext.TestDirectory + "/GenericStringTests.log", deleteOnClose: true);
     fkv = new FasterKV <int, int>(1L << 20, new LogSettings {
         LogDevice = log, ObjectLogDevice = null
         });
     session = fkv.For(new Functions()).NewSession <Functions>();
 }
コード例 #2
0
ファイル: LockTests.cs プロジェクト: rustedwizard/FASTER
 public void TearDown()
 {
     session.Dispose();
     session = null;
     fkv.Dispose();
     fkv = null;
     log.Dispose();
     log = null;
 }
コード例 #3
0
 public FasterKVServerSessionBase(Socket socket, FasterKV <Key, Value> store, Functions functions,
                                  SessionVariableLengthStructSettings <Value, Input> sessionVariableLengthStructSettings,
                                  ParameterSerializer serializer, MaxSizeSettings maxSizeSettings)
     : base(socket, maxSizeSettings)
 {
     session = store.For(new ServerKVFunctions <Key, Value, Input, Output, Functions>(functions, this))
               .NewSession <ServerKVFunctions <Key, Value, Input, Output, Functions> >(sessionVariableLengthStructSettings: sessionVariableLengthStructSettings);
     this.serializer = serializer;
 }
コード例 #4
0
ファイル: LockTests.cs プロジェクト: tli2/FASTER
 public void Setup()
 {
     TestUtils.DeleteDirectory(TestUtils.MethodTestDir, wait: true);
     log = Devices.CreateLogDevice(TestUtils.MethodTestDir + "/GenericStringTests.log", deleteOnClose: true);
     fkv = new FasterKV <int, int>(1L << 20, new LogSettings {
         LogDevice = log, ObjectLogDevice = null
         });
     session = fkv.For(new Functions()).NewSession <Functions>();
 }
コード例 #5
0
ファイル: LockTests.cs プロジェクト: tli2/FASTER
        public void TearDown()
        {
            session?.Dispose();
            session = null;
            fkv?.Dispose();
            fkv = null;
            log?.Dispose();
            log = null;

            TestUtils.DeleteDirectory(TestUtils.MethodTestDir);
        }