Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
3.5.0
-
None
-
Unknown
Description
module:
camel-cloud 3.5.0
stack:
java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:836)
java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(AbstractQueuedSynchronizer.java:997)
java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(AbstractQueuedSynchronizer.java:1304)
java.util.concurrent.CountDownLatch.await(CountDownLatch.java:231)
org.apache.camel.impl.engine.DefaultAsyncProcessorAwaitManager.await(DefaultAsyncProcessorAwaitManager.java:107)
org.apache.camel.impl.engine.DefaultAsyncProcessorAwaitManager.process(DefaultAsyncProcessorAwaitManager.java:85)
org.apache.camel.support.AsyncProcessorSupport.process(AsyncProcessorSupport.java:41)
org.apache.camel.component.resilience4j.ResilienceProcessor$CircuitBreakerTask.call(ResilienceProcessor.java:418)
org.apache.camel.component.resilience4j.ResilienceProcessor$CircuitBreakerTask.call(ResilienceProcessor.java:399)
io.github.resilience4j.circuitbreaker.CircuitBreaker.lambda$decorateCallable$3(CircuitBreaker.java:700)
io.github.resilience4j.circuitbreaker.CircuitBreaker$$Lambda$1027/242448823.call(Unknown Source)
Related codes:
1、org.apache.camel.component.ribbon.cloud.RibbonServiceLoadBalancer#process
when server is null,throw RejectedExecutionException:
throw new RejectedExecutionException("No active services with name " + serviceName);
2、org.apache.camel.impl.cloud.DefaultServiceCallProcessor#process
when catch Exception,we need “callback.done(true);” for CountDownLatch
test code:
RouteDefinition definition = from("...");
CircuitBreakerDefinition circuitBreakerDefinition = definition
.circuitBreaker()
.resilience4jConfiguration(resilience4j)......
erviceCallDefinition serviceCallDefinition = processorDefinition
.serviceCall().name("test-app/api/test/hello");
//registry
ZooKeeperServiceCallServiceDiscoveryConfiguration conf =
new ZooKeeperServiceCallDiscoveryConfiguration(serviceCallDefinition)
.nodes("...").basePath("...").connectionTimeout("7000").sessionTimeout("60000");
serviceCallDefinition.setServiceDiscoveryConfiguration(conf);
//end
serviceCallDefinition.end();