Open majidvodworks opened 7 years ago
Make sure you order the aspects /interceptors so they run in the order you want. Eg hystrix before cache
I did but still it is not working Here is how I did it. @Bean @Order(value = Ordered.HIGHEST_PRECEDENCE) public HystrixCommandAspect hystrixAspect() { return new HystrixCommandAspect(); }
@EnableCaching(order= Ordered.LOWEST_PRECEDENCE)
Hi All, I'm trying to use use spring cloud hystrix with spring cacheable annotation, it is not working. following is code sample
@Cacheable(value = "test", sync = true) @HystrixCommand(fallbackMethod="recoverGetValue") public String getValue(int id) { return id + ""; }
public String recoverGetValue(int id) { System.out.println("getting data from different resource"); return id + ""; }
Cacheable annotation throws operationTimeoutException, but fallback method is not being called. How to solve this issue?