Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3290)

Unified Diff: chrome/common/extensions/docs/server2/in_memory_memcache.py

Issue 10823105: Extensions Docs Server: Preview server and more integration tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/docs/server2/in_memory_memcache.py
diff --git a/chrome/common/extensions/docs/server2/in_memory_memcache.py b/chrome/common/extensions/docs/server2/in_memory_memcache.py
deleted file mode 100644
index bbaddbfe0d8501ff5e475f29d7bc0bf1072b3d49..0000000000000000000000000000000000000000
--- a/chrome/common/extensions/docs/server2/in_memory_memcache.py
+++ /dev/null
@@ -1,24 +0,0 @@
-# Copyright (c) 2012 The Chromium Authors. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-class InMemoryMemcache(object):
- """A memcache that stores items in memory instead of using the memcache
- module.
- """
- def __init__(self):
- self._cache = {}
-
- def set(self, key, value, namespace, time=60):
- if namespace not in self._cache:
- self._cache[namespace] = {}
- self._cache[namespace][key] = value
-
- def get(self, key, namespace):
- if namespace not in self._cache:
- return None
- return self._cache[namespace].get(key, None)
-
- def delete(self, key, namespace):
- if namespace in self._cache:
- self._cache[namespace].pop(key)

Powered by Google App Engine
This is Rietveld 408576698