This is an automated email from the ASF dual-hosted git repository.
liuhongyu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shenyu.git
The following commit(s) were added to refs/heads/master by this push:
new 9e8576a2ae fix: fix redisReteLimter type cast error, for #6103 (#6120)
9e8576a2ae is described below
commit 9e8576a2aec00317076a18bb04933b4bfe42a366
Author: shown <[email protected]>
AuthorDate: Fri Aug 29 20:49:45 2025 +0800
fix: fix redisReteLimter type cast error, for #6103 (#6120)
Signed-off-by: yuluo-yx <[email protected]>
---
.../apache/shenyu/plugin/ratelimiter/executor/RedisRateLimiter.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git
a/shenyu-plugin/shenyu-plugin-fault-tolerance/shenyu-plugin-ratelimiter/src/main/java/org/apache/shenyu/plugin/ratelimiter/executor/RedisRateLimiter.java
b/shenyu-plugin/shenyu-plugin-fault-tolerance/shenyu-plugin-ratelimiter/src/main/java/org/apache/shenyu/plugin/ratelimiter/executor/RedisRateLimiter.java
index 094273225a..c55187f6dd 100644
---
a/shenyu-plugin/shenyu-plugin-fault-tolerance/shenyu-plugin-ratelimiter/src/main/java/org/apache/shenyu/plugin/ratelimiter/executor/RedisRateLimiter.java
+++
b/shenyu-plugin/shenyu-plugin-fault-tolerance/shenyu-plugin-ratelimiter/src/main/java/org/apache/shenyu/plugin/ratelimiter/executor/RedisRateLimiter.java
@@ -65,8 +65,8 @@ public class RedisRateLimiter {
longs.addAll(l);
return longs;
}).map(results -> {
- boolean allowed = results.get(0) == 1L;
- Long tokensLeft = results.get(1);
+ boolean allowed = ((Number) results.get(0)).longValue() ==
1L;
+ long tokensLeft = ((Number) results.get(1)).longValue();
return new RateLimiterResponse(allowed, tokensLeft, keys);
})
.doOnError(throwable -> {