Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
D
Django-Redis-Cache
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shared
Django-Redis-Cache
Commits
00ca1c07
Commit
00ca1c07
authored
Jun 22, 2011
by
Lior Sion
Committed by
Sean Bleier
Jun 22, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
initialize connection pool correctly
parent
02e5c420
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
cache.py
redis_cache/cache.py
+3
-1
No files found.
redis_cache/cache.py
View file @
00ca1c07
from
django.core.cache.backends.base
import
BaseCache
,
InvalidCacheBackendError
from
django.utils.encoding
import
smart_unicode
,
smart_str
from
django.utils.datastructures
import
SortedDict
from
django.conf
import
settings
try
:
import
cPickle
as
pickle
...
...
@@ -73,7 +74,8 @@ class CacheClass(BaseCache):
host
=
server
or
'localhost'
port
=
6379
self
.
_cache
=
redis
.
Redis
(
host
=
host
,
port
=
port
,
db
=
db
,
password
=
password
,
connection_pool
=
pool
.
get_connection_pool
())
password
=
password
,
connection_pool
=
pool
.
get_connection_pool
(
host
=
host
,
port
=
port
,
db
=
db
,
password
=
password
))
def
make_key
(
self
,
key
,
version
=
None
):
"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment