Commit 6fc7158a authored by Ivan Tyagov's avatar Ivan Tyagov

Do not set high debug level to memcached plugin (this will print on stdout).

Fix imports.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@24633 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 8a861a9b
......@@ -29,12 +29,8 @@
"""
Memcached based cache plugin.
"""
from time import time
from thread import get_ident
from zLOG import LOG
from BaseCache import BaseCache
from BaseCache import CacheEntry
......@@ -52,8 +48,7 @@ class DistributedRamCache(BaseCache):
def __init__(self, params):
self._servers = params.get('server', '')
self._debugLevel = params.get('debugLevel', 7)
self._last_cache_conn_creation_time = time()
self._debugLevel = params.get('debugLevel', 0)
BaseCache.__init__(self)
def initCacheStorage(self):
......@@ -79,7 +74,6 @@ class DistributedRamCache(BaseCache):
## we have memcache_conn for this thread
return memcache_conn
def checkAndFixCacheId(self, cache_id, scope):
## memcached doesn't support namespaces (cache scopes) so to "emmulate"
## such behaviour when constructing cache_id we add scope in front
......
......@@ -31,9 +31,7 @@ Local RAM based cache plugin.
"""
import time
from BaseCache import BaseCache
from BaseCache import CacheEntry
from BaseCache import BaseCache, CacheEntry
def calcPythonObjectMemorySize(i):
""" Recursive function that will 'walk' over complex python types and caclulate
......
......@@ -33,12 +33,8 @@ SQL (MySQL) based cache plugin.
from thread import get_ident
import time
import base64
from zLOG import LOG
from BaseCache import BaseCache
from BaseCache import CacheEntry
from BaseCache import CachedMethodError
from BaseCache import BaseCache, CacheEntry, CachedMethodError
try:
import cPickle as pickle
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment