amogh-jahagirdar commented on code in PR #14358: URL: https://github.com/apache/iceberg/pull/14358#discussion_r2441442509
########## flink/v2.1/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/DynamicWriteResultAggregator.java: ########## @@ -61,23 +58,24 @@ class DynamicWriteResultAggregator private static final Logger LOG = LoggerFactory.getLogger(DynamicWriteResultAggregator.class); private static final byte[] EMPTY_MANIFEST_DATA = new byte[0]; - private static final Duration CACHE_EXPIRATION_DURATION = Duration.ofMinutes(1); private final CatalogLoader catalogLoader; + private final int cacheMaximumSize; private long lastCheckpointId = CheckpointIDCounter.INITIAL_CHECKPOINT_ID - 1; private transient Map<WriteTarget, Collection<DynamicWriteResult>> results; - private transient Cache<String, Map<Integer, PartitionSpec>> specs; - private transient Cache<String, ManifestOutputFileFactory> outputFileFactories; + private transient Map<String, Map<Integer, PartitionSpec>> specs; Review Comment: @pvary just curious I had the opposite question, why not a map? Do we expect some huge amount of stats or output file factories? I'd expect those to be pretty small. -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
