danny0405 commented on a change in pull request #10620:
[FLINK-15239][table-planner-blink] TM Metaspace memory leak
URL: https://github.com/apache/flink/pull/10620#discussion_r361083233
##########
File path:
flink-table/flink-table-runtime-blink/src/main/java/org/apache/flink/table/runtime/generated/CompileUtils.java
##########
@@ -45,7 +48,7 @@
* number of Meta zone GC (class unloading), resulting in performance
bottlenecks. So we add
* a cache to avoid this problem.
*/
- protected static final Cache<Tuple2<ClassLoader, String>, Class<?>>
COMPILED_CACHE = CacheBuilder
+ protected static final Cache<String, Cache<ClassLoader, Class>>
COMPILED_CACHE = CacheBuilder
.newBuilder()
.maximumSize(100) // estimated cache size
Review comment:
Why not invoke `.softValues()` here instead of a new `Cache` value ?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services