Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2007-09-17 20:30:53 +0000
committerEike Stepper2007-09-17 20:30:53 +0000
commit410cfefd09aadfe7b9763ac739af09eaa37c27d8 (patch)
treecb8d5bcc55a7b3e20412ad511247a0283f418fc6
parentb901260d71163803dc498a0f2fa23bbbd677c632 (diff)
downloadcdo-410cfefd09aadfe7b9763ac739af09eaa37c27d8.tar.gz
cdo-410cfefd09aadfe7b9763ac739af09eaa37c27d8.tar.xz
cdo-410cfefd09aadfe7b9763ac739af09eaa37c27d8.zip
[203538] Limit memory consumption in CDORevisionResolverImpl
https://bugs.eclipse.org/bugs/show_bug.cgi?id=203538
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICache.java21
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheProbe.java8
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheRegistration.java8
3 files changed, 9 insertions, 28 deletions
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICache.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICache.java
index 8dec5063b8..c08aed9ae0 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICache.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICache.java
@@ -15,29 +15,10 @@ package org.eclipse.net4j.util.cache;
*/
public interface ICache
{
-
public ICacheMonitor getCacheMonitor();
/**
- * Returns the number of elements in the cache that would currently be subject to eviction.
- */
- public int getEvictableElementCount();
-
- /**
- * Returns the average size of an element currently in the cache or <code>UNKNOWN_ELEMENT_SIZE</code> if the
- * implementor of this method is not able or willing to calculate the average element size.
- */
- public int getAverageElementSize();
-
- /**
- * Returns the average time in milliseconds needed to reconstruct an element during a cache miss or
- * <code>UNKNOWN_RECONSTRUCTION_TIME</code> if the implementor of this method is not able or willing to calculate
- * the average reconstruction time.
- */
- public long getAverageReconstructionTime();
-
- /**
- * Instructs this cache to evict <b>elementCount</b> elements and return the number of actually evicted elements.
+ * Instructs this cache to evict <b>elementCount</b> elements.
*/
public void evictElements(int elementCount);
}
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheProbe.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheProbe.java
index 66805fa77e..5d9c26055a 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheProbe.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheProbe.java
@@ -22,4 +22,12 @@ public interface ICacheProbe
public void elementEvicted(int elementSize);
public void elementReconstructed(long reconstructionTime);
+
+ public int getElementCount();
+
+ public long getCacheSize();
+
+ public long getAverageElementSize();
+
+ public long getReconstructionCost();
}
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheRegistration.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheRegistration.java
index ac4858021e..7dbb386fd1 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheRegistration.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/cache/ICacheRegistration.java
@@ -20,12 +20,4 @@ public interface ICacheRegistration extends ICacheProbe
public ICache getCache();
public void dispose();
-
- public int getElementCount();
-
- public long getCacheSize();
-
- public long getAverageElementSize();
-
- public long getReconstructionCost();
}

Back to the top