[bugfix] Mp4: set single_range when ngx_http_mp4_process()returns NGX_OK.

Maxim Dounin mdounin at mdounin.ru
Mon Mar 27 16:38:33 UTC 2017


Hello!

On Tue, Mar 28, 2017 at 12:18:13AM +0800, 胡聪 (hucc) wrote:

> On Monday, Mar 27, 2017 11:31 PM +0300, Maxim Dounin wrote:
> 
> >What's the goal of this patch?
> >Do you want mp4 to handle multi-range requests?  Have you ever 
> >seen clients doing such requests?
> 
> yes, I want mp4 to handle multi-range requests is that case. If it can do it,
> why not? In addition, the patch ensures that the usage scenarios of single_range
> is consistant which helps to understand the flag.

The problem here is consistency and predictability from user point 
of view as well.  If nginx can handle multi-range requests in some 
cases, but not in others, it creates a huge problem for anyone who 
is trying to understand why things do not work.  To simplify 
things, nginx unconditionally disables multi-range requests if 
there were any start/end arguments.

> I have not seen a similar request yet. I just recently developed some modules
> which makes me care about this flag.

Ok, thank you for confirmation.

You may want to re-think your design, multi-range requests are 
believed to be too complicated to work properly, and just can't 
work in many practical cases.  Using separate single-range 
requests may be a better idea.

-- 
Maxim Dounin
http://nginx.org/


More information about the nginx-devel mailing list