public void Add(RelationalTransaction trn) { lock (transactions) { transactions.Add(trn); var numberOfTransactions = transactions.Count; if (numberOfTransactions > MaxPoolSize * 0.8) { Log.Info($"{numberOfTransactions} transactions active"); } if (numberOfTransactions >= MaxPoolSize || numberOfTransactions == (int)(MaxPoolSize * 0.9)) { LogHighNumberOfTransactions(numberOfTransactions >= MaxPoolSize); } } }
public void Remove(RelationalTransaction trn) { lock (transactions) transactions.Remove(trn); }