示例#1
0
        /// <summary>
        ///     Refer to <see cref="Confluent.Kafka.IConsumer{TKey,TValue}.Close" />.
        /// </summary>
        public void Close()
        {
            // commits offsets and unsubscribes.
            kafkaHandle.ConsumerClose();

            Dispose(true);
            GC.SuppressFinalize(this);
        }
示例#2
0
        /// <inheritdoc/>
        public void Close()
        {
            // commits offsets and unsubscribes.
            kafkaHandle.ConsumerClose();
            if (this.handlerException != null)
            {
                var ex = this.handlerException;
                this.handlerException = null;
                throw ex;
            }

            Dispose(true);
            GC.SuppressFinalize(this);
        }