The complete error is as follows:
java.util.concurrent.TimeoutException: null at com.netflix.hystrix.AbstractCommand.handleTimeoutViaFallback(AbstractCommand.java:997) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.AbstractCommand.access$500(AbstractCommand.java:60) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.AbstractCommand$12.call(AbstractCommand.java:609) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.AbstractCommand$12.call(AbstractCommand.java:601) ~[hystrix-core-1.5.18.jar:1.5.18] at rx.internal.operators.OperatorOnErrorResumeNextViaFunction$4.onError(OperatorOnErrorResumeNextViaFunction.java:140) ~[rxjava-1.3.8.jar:1.3.8] at rx.internal.operators.OnSubscribeDoOnEach$DoOnEachSubscriber.onError(OnSubscribeDoOnEach.java:87) ~[rxjava-1.3.8.jar:1.3.8] at rx.internal.operators.OnSubscribeDoOnEach$DoOnEachSubscriber.onError(OnSubscribeDoOnEach.java:87) ~[rxjava-1.3.8.jar:1.3.8] at com.netflix.hystrix.AbstractCommand$HystrixObservableTimeoutOperator$1.run(AbstractCommand.java:1142) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.strategy.concurrency.HystrixContextRunnable$1.call(HystrixContextRunnable.java:41) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.strategy.concurrency.HystrixContextRunnable$1.call(HystrixContextRunnable.java:37) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.strategy.concurrency.HystrixContextRunnable.run(HystrixContextRunnable.java:57) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.AbstractCommand$HystrixObservableTimeoutOperator$2.tick(AbstractCommand.java:1159) ~[hystrix-core-1.5.18.jar:1.5.18] at com.netflix.hystrix.util.HystrixTimer$1.run(HystrixTimer.java:99) ~[hystrix-core-1.5.18.jar:1.5.18] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_221] at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:1.8.0_221] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:1.8.0_221] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:1.8.0_221] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_221] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_221] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_221]
I asked Du Niang, there are those with the function of closing the circuit breaker, and those with a longer circuit breaker time, which are not on the point at all. My purpose is to test the function of the Hystrix circuit breaker, and they are all closed. How can I verify it? Later, I found that there was a line of error on top of this error:
com.netflix.hystrix.contrib.javanica.command.GenericCommand.getFallback 80 - failed to processed fallback is the method: 'failHi'.
Debugging the com.netflix.hystrix.contrib.javanica.command.GenericCommand.getFallback method, it is found that the @HystrixCommand annotation defines the fallbackMethod method to reflect the failure to call failHi, and the failHi method that reported the error is debugged again. Finally, it is found that a RuntimeException exception occurred in the failHi method. The wrong example code is as follows:
@HystrixCommand(fallbackMethod = "failHi") @ResponseBody @GetMapping("/hi3") public String hi3() { return restTemplate.getForObject("http://127.0.0.1:" + port + "/res", String.class); } public String failHi() { try { return doThings(); } catch (Exception e) { throw new RuntimeException("error," + e.getMessage()); } }
Read More:
- [Solved] Error: exception: java.lang.reflect.InvocationTargetException: null
- [Solved] java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/util/ByteArrayBuffer
- [Solved] Groovy Project Compile Error: java.lang.NoClassDefFoundError: org/apache/tools/ant/util/ReaderInputStream
- Start error in maven web project java.lang.ClassNotFoundException: org.springframework.web.util.Log4jConfigListener
- Android Working Directory:NULL Environment:NULL Error
- JPA @ManyToMany java.lang.StackOverflowError: null [How to Solve]
- [Solved] Springboot Reflection calls ServiceImpl Error: java.lang.NullPointerException, mapper is null
- TypeException: Error setting non null for parameter #1 with JdbcType null
- [Solved] JOptionPane Error: java.awt.HeadlessException: null
- [Solved] Error: Cannot run with sound null safety, because the following dependenciesdon‘t support null safe
- [Solved] Golang Error: fatal error: concurrent map writes
- Mybatis Integrate SQLSERER Null Value Error: Error setting null for parameter # with JdbcType OTHER
- [Go] Solve the fatal error: concurrent map writes map is not concurrently safe
- How to Solve Go Error: concurrent map iteration and map write
- Golang Error: fatal error: concurrent map read and map writ
- Error: uncaughtexception: cannot find module ‘internal / util / types’
- [Solved] habse Start Error: Error: Could not find or load main class org.apache.hadoop.hbase.util.GetJavaProperty
- [Solved] JNI DETECTED ERROR IN APPLICATION: GetStringUTFChars received NULL jstring
- [Solved] Response Export error on submit request on future invoke, java.lang.OutOfMemoryError: Java heap space
- failed: RawInventory gets null OracleHomeInfo [How to Solve]