|
|
|
@ -20,7 +20,6 @@ import java.lang.reflect.Method; |
|
|
|
import java.util.Map; |
|
|
|
import java.util.Map; |
|
|
|
import java.util.concurrent.ConcurrentHashMap; |
|
|
|
import java.util.concurrent.ConcurrentHashMap; |
|
|
|
|
|
|
|
|
|
|
|
import org.aopalliance.intercept.Joinpoint; |
|
|
|
|
|
|
|
import org.aopalliance.intercept.MethodInterceptor; |
|
|
|
import org.aopalliance.intercept.MethodInterceptor; |
|
|
|
import org.aopalliance.intercept.MethodInvocation; |
|
|
|
import org.aopalliance.intercept.MethodInvocation; |
|
|
|
import org.jspecify.annotations.Nullable; |
|
|
|
import org.jspecify.annotations.Nullable; |
|
|
|
@ -93,8 +92,8 @@ public class ConcurrencyLimitBeanPostProcessor extends AbstractBeanFactoryAwareA |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
if (interceptor == null) { |
|
|
|
if (interceptor == null) { |
|
|
|
interceptor = (limit != null ? new ConcurrencyThrottleInterceptor(limit.value()) : |
|
|
|
Assert.state(limit != null, "No @ConcurrencyLimit annotation found"); |
|
|
|
Joinpoint::proceed); |
|
|
|
interceptor = new ConcurrencyThrottleInterceptor(limit.value()); |
|
|
|
if (!perMethod) { |
|
|
|
if (!perMethod) { |
|
|
|
cache.classInterceptor = interceptor; |
|
|
|
cache.classInterceptor = interceptor; |
|
|
|
} |
|
|
|
} |
|
|
|
|