From 14c703361d436beb1947254724daa17f5a2775fc Mon Sep 17 00:00:00 2001 From: Hugo Hills <39260692+hugohills-regnosys@users.noreply.github.com> Date: Wed, 18 Sep 2024 11:22:23 +0100 Subject: [PATCH] Disabled cache (#843) Co-authored-by: Simon Cockx --- .../rosetta/cache/RequestScopedCache.java | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/rosetta-lang/src/main/java/com/regnosys/rosetta/cache/RequestScopedCache.java b/rosetta-lang/src/main/java/com/regnosys/rosetta/cache/RequestScopedCache.java index c145b29a3..0231e920c 100644 --- a/rosetta-lang/src/main/java/com/regnosys/rosetta/cache/RequestScopedCache.java +++ b/rosetta-lang/src/main/java/com/regnosys/rosetta/cache/RequestScopedCache.java @@ -27,20 +27,20 @@ public RequestScopedCache(int initialCapacity) { @SuppressWarnings("unchecked") public T get(Object key, Provider provider) { - Object v = values.get(key); - if (v == NULL) { - return null; - } - if (v != null) { - return (T)v; - } +// Object v = values.get(key); +// if (v == NULL) { +// return null; +// } +// if (v != null) { +// return (T)v; +// } T computed = provider.get(); - if (computed == null) { - values.put(key, NULL); - } else { - values.put(key, computed); - } +// if (computed == null) { +// values.put(key, NULL); +// } else { +// values.put(key, computed); +// } return computed; }