private void StartCreating(CancellationToken cancellationToken) { var addingConnectionEvent = new ConnectionPoolAddingConnectionEvent(_pool._serverId, EventContext.OperationId); _pool._addingConnectionEventHandler?.Invoke(addingConnectionEvent); cancellationToken.ThrowIfCancellationRequested(); _stopwatch = Stopwatch.StartNew(); _connection = _pool.CreateNewConnection(); }
private void Handle(ConnectionPoolAddingConnectionEvent @event) { Debug(TraceSourceEventHelper.ConnectionPoolIdBase + 4, "{0}-pool: adding connection.", TraceSourceEventHelper.Label(@event.ServerId)); }