From b27214a69c30e9956bde1121f691e4922bbc2492 Mon Sep 17 00:00:00 2001 From: chenzhiguo Date: Mon, 6 Jan 2025 11:01:27 +0800 Subject: [PATCH] Fix close update condition error --- .../agent/governance/invoke/ratelimit/AbstractRateLimiter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/joylive-core/joylive-governance-api/src/main/java/com/jd/live/agent/governance/invoke/ratelimit/AbstractRateLimiter.java b/joylive-core/joylive-governance-api/src/main/java/com/jd/live/agent/governance/invoke/ratelimit/AbstractRateLimiter.java index 777a3811..fd8a92e3 100644 --- a/joylive-core/joylive-governance-api/src/main/java/com/jd/live/agent/governance/invoke/ratelimit/AbstractRateLimiter.java +++ b/joylive-core/joylive-governance-api/src/main/java/com/jd/live/agent/governance/invoke/ratelimit/AbstractRateLimiter.java @@ -102,7 +102,7 @@ public boolean acquire(int permits, long timeout, TimeUnit timeUnit) { @Override public void close() { - if (started.compareAndSet(false, true)) { + if (started.compareAndSet(true, false)) { doClose(); } }