예제 #1
0
        public ICompletes <Response> RequestWith(Request request)
        {
            var completes = _configuration.KeepAlive
                ? Completes.RepeatableUsing <Response>(_configuration.Stage.Scheduler)
                : Completes.Using <Response>(_configuration.Stage.Scheduler);

            _consumer.RequestWith(request, completes);
            return(completes);
        }
예제 #2
0
        public ICompletes <Response> RequestWith(Request request)
        {
            var completes = _configuration.KeepAlive
                ? Completes.RepeatableUsing <Response>(_configuration.Stage.Scheduler)
                : Completes.Using <Response>(_configuration.Stage.Scheduler);

            request.Headers.And(RequestHeader.Connection, _configuration.KeepAlive ? Header.ValueKeepAlive : Header.ValueClose);
            _consumer.RequestWith(request, completes);
            return(completes);
        }