Skip to content

Commit

Permalink
Updates bucket4j to 8.14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
spencergibb committed Dec 4, 2024
1 parent 3122ba7 commit 7db16a7
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 11 deletions.
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<bucket4j.version>8.10.1</bucket4j.version>
<bucket4j.version>8.14.0</bucket4j.version>
<blockhound.version>1.0.8.RELEASE</blockhound.version>
<java.version>17</java.version>
<junit-pioneer.version>2.3.0</junit-pioneer.version>
Expand Down Expand Up @@ -99,12 +99,12 @@
</dependency>
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-core</artifactId>
<artifactId>bucket4j_jdk17-core</artifactId>
<version>${bucket4j.version}</version>
</dependency>
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-caffeine</artifactId>
<artifactId>bucket4j_jdk17-caffeine</artifactId>
<version>${bucket4j.version}</version>
</dependency>
<dependency>
Expand Down
4 changes: 2 additions & 2 deletions spring-cloud-gateway-server-mvc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
<!-- Third party dependencies -->
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-core</artifactId>
<artifactId>bucket4j_jdk17-core</artifactId>
<optional>true</optional>
</dependency>
<!-- Spring test dependencies -->
Expand All @@ -92,7 +92,7 @@
<!-- Third party test dependencies -->
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-caffeine</artifactId>
<artifactId>bucket4j_jdk17-caffeine</artifactId>
<scope>test</scope>
</dependency>
<dependency>
Expand Down
7 changes: 2 additions & 5 deletions spring-cloud-gateway-server/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
<main.basedir>${basedir}/..</main.basedir>
<grpc.version>1.68.1</grpc.version>
<context-propagation.version>1.0.0</context-propagation.version>
<bucket4j-core.version>8.3.0</bucket4j-core.version>
</properties>

<dependencies>
Expand Down Expand Up @@ -139,14 +138,12 @@
</dependency>
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-core</artifactId>
<version>${bucket4j-core.version}</version>
<artifactId>bucket4j_jdk17-core</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-caffeine</artifactId>
<version>${bucket4j-core.version}</version>
<artifactId>bucket4j_jdk17-caffeine</artifactId>
<scope>test</scope>
</dependency>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -738,17 +738,18 @@ static ConfigurableHintsRegistrationProcessor configurableHintsRegistrationProce
return new ConfigurableHintsRegistrationProcessor();
}


@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(AsyncProxyManager.class)
protected static class Bucket4jConfiguration {

@Bean
@ConditionalOnBean(AsyncProxyManager.class)
@ConditionalOnEnabledFilter(RequestRateLimiterGatewayFilterFactory.class)
public Bucket4jRateLimiter bucket4jRateLimiter(AsyncProxyManager<String> proxyManager,
ConfigurationService configurationService) {
return new Bucket4jRateLimiter(proxyManager, configurationService);
}

}

@Configuration(proxyBeanMethods = false)
Expand Down

0 comments on commit 7db16a7

Please sign in to comment.