From b023ff136e06e89be09b467e5565f93c07d08479 Mon Sep 17 00:00:00 2001 From: Spencer Perkins <95900100+SpecialThing44@users.noreply.github.com> Date: Thu, 17 Apr 2025 15:36:27 -0400 Subject: [PATCH] Update comment and variables to match cache type --- .../scala/org/neo4j/cypher/internal/ExecutionEngine.scala | 4 ++-- .../org/neo4j/cypher/internal/compatibility/LFUCache.scala | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/ExecutionEngine.scala b/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/ExecutionEngine.scala index 8ede1bfaedd..7a97912adea 100644 --- a/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/ExecutionEngine.scala +++ b/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/ExecutionEngine.scala @@ -189,8 +189,8 @@ class ExecutionEngine(val queryService: GraphDatabaseQueryService, // fetch plan cache val cache: QueryCache[String, (ExecutionPlan, Map[String, Any], Seq[String])] = getOrCreateFromSchemaState(tc.schemaRead, { cacheMonitor.cacheFlushDetected(tc.statement) - val lruCache = new LFUCache[String, (ExecutionPlan, Map[String, Any], Seq[String])](getPlanCacheSize) - new QueryCache(cacheAccessor, lruCache) + val lfuCache = new LFUCache[String, (ExecutionPlan, Map[String, Any], Seq[String])](getPlanCacheSize) + new QueryCache(cacheAccessor, lfuCache) }) def isStale(plan: ExecutionPlan, ignored1: Map[String, Any], ignored2: Seq[String]) = plan.isStale(lastCommittedTxId, tc) diff --git a/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/compatibility/LFUCache.scala b/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/compatibility/LFUCache.scala index 2d4f426b2ee..9081f07226d 100644 --- a/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/compatibility/LFUCache.scala +++ b/community/cypher/cypher/src/main/scala/org/neo4j/cypher/internal/compatibility/LFUCache.scala @@ -67,7 +67,7 @@ class LFUCache[K <: AnyRef, V <: AnyRef](val size: Int) extends ((K, => V) => V) def apply(key: K, value: => V): V = getOrElseUpdate(key, value) /** - * Method for clearing the LRUCache + * Method for clearing the LFUCache * @return the number of elements in the cache prior to the clearing */ def clear(): Long = {