コード例 #1
0
        public void Close()
        {
            if (_connection != null)
            {
                _connection.Close();
            }

            _stopExecutionThread = true;
        }
コード例 #2
0
        public void Close()
        {
            _stopping = true;

            lock (_connectionLock)
            {
                _connection.Close();
            }
            _subscriptionsChannel.Close();

            var items = _inProgress.Values;

            _inProgress.Clear();
            foreach (var workItem in items)
            {
                workItem.Operation.Fail(new ConnectionClosingException(
                                            "Work item was still in progress at the moment of manual connection closing"));
            }

            _log.Info("EventStoreConnection closed.");
        }
コード例 #3
0
        public void Close(bool stopBackgroundThread = true)
        {
            lock (_subscriptionChannelLock)
            {
                if (_connection != null)
                {
                    _connection.Close();
                }

                _stopExecutionThread = stopBackgroundThread;
            }
        }