summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/java/com/gitblit/manager/RepositoryManager.java2
-rw-r--r--src/main/java/com/gitblit/utils/ObjectCache.java4
2 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/com/gitblit/manager/RepositoryManager.java b/src/main/java/com/gitblit/manager/RepositoryManager.java
index 438d885c..0a3f6631 100644
--- a/src/main/java/com/gitblit/manager/RepositoryManager.java
+++ b/src/main/java/com/gitblit/manager/RepositoryManager.java
@@ -457,6 +457,8 @@ public class RepositoryManager implements IRepositoryManager {
public void resetRepositoryListCache() {
logger.info("Repository cache manually reset");
repositoryListCache.clear();
+ repositorySizeCache.clear();
+ repositoryMetricsCache.clear();
}
/**
diff --git a/src/main/java/com/gitblit/utils/ObjectCache.java b/src/main/java/com/gitblit/utils/ObjectCache.java
index 48a9668d..e75d4b86 100644
--- a/src/main/java/com/gitblit/utils/ObjectCache.java
+++ b/src/main/java/com/gitblit/utils/ObjectCache.java
@@ -54,6 +54,10 @@ public class ObjectCache<X> implements Serializable {
}
}
+ public void clear() {
+ cache.clear();
+ }
+
public boolean hasCurrent(String name, Date date) {
return cache.containsKey(name) && cache.get(name).date.compareTo(date) == 0;
}