Users are kept in runtime storage during update cycle

* Users are persisted by user_id and accessed from web font directly
* Web app initializing section is refactored
* 404 error handler is made more looking like error

Closes bug 1213841

Change-Id: Ie6ff57505dcc14291cd3267a7448cddb2b478eb2
This commit is contained in:
Ilya Shakhat
2013-08-19 16:57:18 +04:00
parent 662a328cb8
commit 5a7da39e7d
7 changed files with 117 additions and 86 deletions

View File

@@ -115,10 +115,10 @@ class MemcachedStorage(RuntimeStorage):
self._commit_update(record_id)
def get_by_key(self, key):
return self.memcached.get(key)
return self.memcached.get(key.encode('utf8'))
def set_by_key(self, key, value):
self.memcached.set(key, value)
self.memcached.set(key.encode('utf8'), value)
def get_update(self, pid):
last_update = self.memcached.get('pid:%s' % pid)