From 016f2791d63706de09cc77228c6282c06574d611 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Thu, 26 Feb 2015 13:24:38 -0500 Subject: remove dead throttle code --- .../HttpServer/HttpResultFactory.cs | 8 -------- .../HttpServer/RangeRequestWriter.cs | 12 ------------ .../HttpServer/StreamWriter.cs | 12 ------------ 3 files changed, 32 deletions(-) (limited to 'MediaBrowser.Server.Implementations/HttpServer') diff --git a/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs b/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs index 681d3ac5e..ecf58e4a6 100644 --- a/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs +++ b/MediaBrowser.Server.Implementations/HttpServer/HttpResultFactory.cs @@ -461,10 +461,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer { return new RangeRequestWriter(rangeHeader, stream, contentType, isHeadRequest) { - Throttle = options.Throttle, - ThrottleLimit = options.ThrottleLimit, - MinThrottlePosition = options.MinThrottlePosition, - ThrottleCallback = options.ThrottleCallback, OnComplete = options.OnComplete }; } @@ -480,10 +476,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer return new StreamWriter(stream, contentType, _logger) { - Throttle = options.Throttle, - ThrottleLimit = options.ThrottleLimit, - MinThrottlePosition = options.MinThrottlePosition, - ThrottleCallback = options.ThrottleCallback, OnComplete = options.OnComplete }; } diff --git a/MediaBrowser.Server.Implementations/HttpServer/RangeRequestWriter.cs b/MediaBrowser.Server.Implementations/HttpServer/RangeRequestWriter.cs index cdd4c6d7c..8c72f9e7e 100644 --- a/MediaBrowser.Server.Implementations/HttpServer/RangeRequestWriter.cs +++ b/MediaBrowser.Server.Implementations/HttpServer/RangeRequestWriter.cs @@ -24,10 +24,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer private long RangeLength { get; set; } private long TotalContentLength { get; set; } - public bool Throttle { get; set; } - public long ThrottleLimit { get; set; } - public long MinThrottlePosition; - public Func ThrottleCallback { get; set; } public Action OnComplete { get; set; } /// @@ -165,14 +161,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer /// The response stream. public void WriteTo(Stream responseStream) { - if (Throttle) - { - responseStream = new ThrottledStream(responseStream, ThrottleLimit) - { - MinThrottlePosition = MinThrottlePosition, - ThrottleCallback = ThrottleCallback - }; - } WriteToInternal(responseStream); } diff --git a/MediaBrowser.Server.Implementations/HttpServer/StreamWriter.cs b/MediaBrowser.Server.Implementations/HttpServer/StreamWriter.cs index 1db14e887..fe662542e 100644 --- a/MediaBrowser.Server.Implementations/HttpServer/StreamWriter.cs +++ b/MediaBrowser.Server.Implementations/HttpServer/StreamWriter.cs @@ -35,10 +35,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer get { return _options; } } - public bool Throttle { get; set; } - public long ThrottleLimit { get; set; } - public long MinThrottlePosition; - public Func ThrottleCallback { get; set; } public Action OnComplete { get; set; } /// @@ -82,14 +78,6 @@ namespace MediaBrowser.Server.Implementations.HttpServer /// The response stream. public void WriteTo(Stream responseStream) { - if (Throttle) - { - responseStream = new ThrottledStream(responseStream, ThrottleLimit) - { - MinThrottlePosition = MinThrottlePosition, - ThrottleCallback = ThrottleCallback - }; - } WriteToInternal(responseStream); } -- cgit v1.2.3