7

如何解决Spring Cloud LoadBalancer is currently working with the default cache. You can switch to using Caffeine cache, by adding it to the classpath.spring boot中的警告?

4

1 回答 1

2

将以下库添加到您的pom.xml

<!-- https://mvnrepository.com/artifact/com.github.ben-manes.caffeine/caffeine -->
<dependency>
    <groupId>com.github.ben-manes.caffeine</groupId>
    <artifactId>caffeine</artifactId>
    <version>2.8.8</version>
</dependency>

或在您的build.gradle

// https://mvnrepository.com/artifact/com.github.ben-manes.caffeine/caffeine
compile group: 'com.github.ben-manes.caffeine', name: 'caffeine', version: '2.8.8'

您可以替换合适/最新版本的caffeine.

于 2020-12-10T02:24:47.943 回答