From bb58ac38cffff65c6882419c2e01ce09df7e8d90 Mon Sep 17 00:00:00 2001 From: Pierre-Emmanuel Jacquier Date: Wed, 2 Oct 2019 16:26:03 +0000 Subject: [PATCH] Update doc Signed-off-by: Pierre-Emmanuel Jacquier --- pkg/routes/xtream.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/routes/xtream.go b/pkg/routes/xtream.go index 65ea1ba..8218e9c 100644 --- a/pkg/routes/xtream.go +++ b/pkg/routes/xtream.go @@ -23,7 +23,7 @@ type cacheMeta struct { time.Time } -// XXX Add one cache per url and store it on the local storage or key/value storage e.g: etcd, redis... +// XXX Use key/value storage e.g: etcd, redis... // and remove that dirty globals var xtreamM3uCache map[string]cacheMeta = map[string]cacheMeta{} var lock = sync.RWMutex{} @@ -85,7 +85,6 @@ func (p *proxy) xtreamGet(c *gin.Context) { return } - // XXX Add cache per url and store it on the local storage or key/value storage e.g: etcd, redis... lock.RLock() meta, ok := xtreamM3uCache[m3uURL.String()] d := time.Now().Sub(meta.Time)