summaryrefslogtreecommitdiffstats
path: root/cobbler/utils.py
diff options
context:
space:
mode:
authorMichael DeHaan <mdehaan@redhat.com>2007-11-14 12:14:56 -0500
committerMichael DeHaan <mdehaan@redhat.com>2007-11-14 12:14:56 -0500
commit39ad540c08a2b9eadefa9862b6bab42e085dafbc (patch)
tree43d7eef0bafd98bdc79942dfdded36e81fb070c1 /cobbler/utils.py
parentd0deea1ae3da2f37814d2ec78fb7c31de6ddbed7 (diff)
downloadthird_party-cobbler-39ad540c08a2b9eadefa9862b6bab42e085dafbc.tar.gz
third_party-cobbler-39ad540c08a2b9eadefa9862b6bab42e085dafbc.tar.xz
third_party-cobbler-39ad540c08a2b9eadefa9862b6bab42e085dafbc.zip
Disable the blender cache as it's running afoul of the sync code, mixing up profiles/systems
data incorrectly when blending objects for cobbler/sync.
Diffstat (limited to 'cobbler/utils.py')
-rw-r--r--cobbler/utils.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/cobbler/utils.py b/cobbler/utils.py
index ad72feb..f9f73b1 100644
--- a/cobbler/utils.py
+++ b/cobbler/utils.py
@@ -280,8 +280,10 @@ def blender(api_handle,remove_hashes, root_obj, blend_cache=None):
consolidated data.
"""
+ cache_enabled = False
+
blend_key = "%s/%s/%s" % (root_obj.TYPE_NAME, root_obj.name, remove_hashes)
- if blend_cache is not None:
+ if cache_enabled and blend_cache is not None:
if blend_cache.has_key(blend_key):
return blend_cache[blend_key]
@@ -323,7 +325,7 @@ def blender(api_handle,remove_hashes, root_obj, blend_cache=None):
if remove_hashes:
results = flatten(results)
- if blend_cache is not None:
+ if cache_enabled and blend_cache is not None:
blend_cache[blend_key] = results
return results