[squid-users] Caching HLS content?

From: Scott Baker <bakers_at_canbytel.com>
Date: Thu, 31 Jan 2013 16:19:53 -0800

I want to make sure that .m3u8 files are *never* cached. Those files are
updated every 5 seconds on my server, and always have the same name.
What is the best way to make sure that they are never cached? This is
what I came up with:

refresh_pattern \.m3u8 0 0% 0

Conversely, MPEG segments are .ts files and are ALWAYS the same. The
file names roll, so once an mpeg segment is created it will *never* get
updated. Thus those files should ALWAYS be cached, and there is no
reason to ever refresh the file. How do I ensure that .ts segments are
cached, and there is no reason to re-validate them. These pieces of
content will expire after 15 minutes (it's live video), so there is no
reason to keep any .ts files that are older than 15 minutes. This is
what I came up with:

refresh_pattern \.ts 900 100% 900

Currently I'm seeing a lot of TCP_REFRESH_UNMODIFIED in my logs for .ts
segments. I must be doing something wrong.

-- 
Scott Baker - Canby Telcom
System Administrator - RHCE - 503.266.8253
Received on Fri Feb 01 2013 - 00:19:59 MST

This archive was generated by hypermail 2.2.0 : Fri Feb 01 2013 - 12:00:05 MST