Пример #1
0
 private Task RenewEngineAsync()
 {
     return(_Pool.DoAsync(() =>
     {
         RenewEngineCore();
     }));
 }
Пример #2
0
 public Task DoAsync(Action <DBreeze.Transactions.Transaction> act)
 {
     AssertNotDisposed();
     return(_Pool.DoAsync(() =>
     {
         AssertNotDisposed();
         RetryIfFailed(() =>
         {
             act(_Tx);
         });
     }));
 }
Пример #3
0
 void AddToTextSearch(string invoiceId, params string[] terms)
 {
     _IndexerThread.DoAsync(() =>
     {
         using (var tx = _Engine.GetTransaction())
         {
             tx.TextAppend("InvoiceSearch", Encoders.Base58.DecodeData(invoiceId), string.Join(" ", terms.Where(t => !String.IsNullOrWhiteSpace(t))));
             tx.Commit();
         }
     });
 }
Пример #4
0
 private void QueueWork(Action act)
 {
     var unused = _ThreadPool.DoAsync(act);
 }