Example #1
0
 public WriteTransaction(
     RelationalTransactionRegistry registry,
     RetriableOperation operationsToRetry,
     IRelationalStoreConfiguration configuration,
     IKeyAllocator keyAllocator,
     string name = null
     ) : base(registry, operationsToRetry, configuration, name)
 {
     this.configuration = configuration;
     this.keyAllocator  = keyAllocator;
     builder            = new DataModificationQueryBuilder(configuration, AllocateId);
 }
Example #2
0
 public ReadTransaction(RelationalTransactionRegistry registry, RetriableOperation operationsToRetry, IRelationalStoreConfiguration configuration, string name = null)
 {
     State                  = new Dictionary <string, object>();
     this.registry          = registry;
     this.operationsToRetry = operationsToRetry;
     this.configuration     = configuration;
     this.name              = name ?? Thread.CurrentThread.Name;
     if (string.IsNullOrEmpty(name))
     {
         this.name = "<unknown>";
     }
     registry.Add(this);
 }