summaryrefslogtreecommitdiffstats
path: root/modules/setting
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2015-11-21 17:21:22 -0500
committerUnknwon <u@gogs.io>2015-11-21 17:21:22 -0500
commit3623b0927eaaa343014a592b4f663f80b9a513b5 (patch)
tree8a3e70bf44effa88a4d8b459894d9091affaac9a /modules/setting
parentd37da1f3929f94703d7c7f19f60288109f95756d (diff)
downloadgitea-3623b0927eaaa343014a592b4f663f80b9a513b5.tar.gz
gitea-3623b0927eaaa343014a592b4f663f80b9a513b5.zip
remove tags redis and memcache
Diffstat (limited to 'modules/setting')
-rw-r--r--modules/setting/setting.go16
-rw-r--r--modules/setting/setting_memcache.go15
-rw-r--r--modules/setting/setting_redis.go16
3 files changed, 4 insertions, 43 deletions
diff --git a/modules/setting/setting.go b/modules/setting/setting.go
index c2b56b5b4c..a8a31ddc7f 100644
--- a/modules/setting/setting.go
+++ b/modules/setting/setting.go
@@ -15,10 +15,12 @@ import (
"strings"
"time"
- "gopkg.in/ini.v1"
-
"github.com/Unknwon/com"
+ _ "github.com/go-macaron/cache/memcache"
+ _ "github.com/go-macaron/cache/redis"
"github.com/go-macaron/session"
+ _ "github.com/go-macaron/session/redis"
+ "gopkg.in/ini.v1"
"github.com/gogits/gogs/modules/bindata"
"github.com/gogits/gogs/modules/log"
@@ -140,9 +142,6 @@ var (
CacheInternal int
CacheConn string
- EnableRedis bool
- EnableMemcache bool
-
// Session settings.
SessionConfig session.Options
@@ -545,13 +544,6 @@ func newLogService() {
func newCacheService() {
CacheAdapter = Cfg.Section("cache").Key("ADAPTER").In("memory", []string{"memory", "redis", "memcache"})
- if EnableRedis {
- log.Info("Redis Supported")
- }
- if EnableMemcache {
- log.Info("Memcache Supported")
- }
-
switch CacheAdapter {
case "memory":
CacheInternal = Cfg.Section("cache").Key("INTERVAL").MustInt(60)
diff --git a/modules/setting/setting_memcache.go b/modules/setting/setting_memcache.go
deleted file mode 100644
index 9a7653b726..0000000000
--- a/modules/setting/setting_memcache.go
+++ /dev/null
@@ -1,15 +0,0 @@
-// +build memcache
-
-// Copyright 2014 The Gogs Authors. All rights reserved.
-// Use of this source code is governed by a MIT-style
-// license that can be found in the LICENSE file.
-
-package setting
-
-import (
- _ "github.com/go-macaron/cache/memcache"
-)
-
-func init() {
- EnableMemcache = true
-}
diff --git a/modules/setting/setting_redis.go b/modules/setting/setting_redis.go
deleted file mode 100644
index e12010cd59..0000000000
--- a/modules/setting/setting_redis.go
+++ /dev/null
@@ -1,16 +0,0 @@
-// +build redis
-
-// Copyright 2014 The Gogs Authors. All rights reserved.
-// Use of this source code is governed by a MIT-style
-// license that can be found in the LICENSE file.
-
-package setting
-
-import (
- _ "github.com/go-macaron/cache/redis"
- _ "github.com/go-macaron/session/redis"
-)
-
-func init() {
- EnableRedis = true
-}