Caffeine removalListener 不生效问题
使用 Caffeine.scheduler让removalListener 生效 private Cache<String, String> cache = Caffeine.newBuilder() .maximumSize(10_000) .scheduler(Scheduler.forScheduledExecutorService(Executors.newScheduledThreadPool(1))) .expireAfterWrite(1, T
原创
2021-02-05 15:12:08 ·
2718 阅读 ·
0 评论