Thanks Claus! Some follow ups on your answers:
1) I have been using camel 2.19.0. What version fixed the bug? 2) hystrix() has methods like getHystrixConfigurations(), is it usable in route dsl? If yes, can you please provide a route DSL example? 3) Thanks for providing the feature in the new commit! I wonder when it will be available and how to use it in route DSL. Can you please also provide an example? On Wed, Oct 11, 2017 at 6:26 AM, Claus Ibsen <[email protected]> wrote: > Hi > > Okay I found out a bit and logged a ticket > https://issues.apache.org/jira/browse/CAMEL-11895? > > You can see this commit that can get the CB state > https://github.com/apache/camel/commit/ebf7b80c23006551f44000befa9a43 > 47817ff97e > > On Wed, Oct 11, 2017 at 3:07 PM, Claus Ibsen <[email protected]> > wrote: > > Ad 1) > > Try upgrading Camel it may be a bug. However that configuration ought > > to be in use. We have some examples that does that and it works. > > > > Ad 2) > > You cannot, you can debug or turn on DEBUG/TRACE logging etc. > > > > Ad 3) > > Dont think its exposed via JMX. > > There is some details today via JMX on the hystrix processor in the > > CAmel jmx tree. It would be nice somehow to get the state of the > > breaker. You can welcome to dive in the code to see if you can find > > out how. > > > > > > It should be standard Hystrix so you can use its api to find the > > circuit breakers and get its state. For example > > HystrixEventStreamService uses a hystrix poller to get a stream of > > data for all the circuit breakers in the JVM which is what its used to > > populate data to the famous Hystrix Dashboard. > > > > Also each CAmel message that is processed via the hystrix has some > > state after being processed, see HystrixConstants > > > > On Tue, Oct 10, 2017 at 9:59 PM, LiQiang Ye <[email protected]> > wrote: > >> Hi, camel friends > >> > >> I have a few questions regarding camel hystrix java dsl. > >> > >> I am using hystrix in a route: > >> > >> > >> from("direct:a").routeId("a_route") > >> .hystrix() > >> //question: how to print out or log configurations for this particular > >> hystrix > >> .to("bean:abean?method=execute") > >> .onFallback() > >> .to("bean:bBean?method=execute") > >> //question: how to check if circuite break is open. If it's open, I > would > >> like to log a message. > >> .end() > >> > >> > >> 1) How can I pass camel hystrix global settings to the hystrix. I've > >> configured the following entries in my application.yml file, but the > >> hystrix didn't seem to pick up the configs. > >> > >> camel: > >> hystrix: > >> execution-timeout-in-milliseconds: 0 > >> circuit-breaker-request-volume-threshold: 5 > >> circuit-breaker-error-threshold-percentage: 50 > >> circuit-breaker-sleep-window-in-milliseconds: 10000 > >> metrics-rolling-percentile-window-in-milliseconds: 20000 > >> metrics-rolling-percentile-window-buckets: 2 > >> > >> 2) In above route, how can I print out a particular hystrix's configs > >> > >> 3) In above route, how do I know if a circuit break is open. > >> > >> > >> Thanks > > > > > > > > -- > > Claus Ibsen > > ----------------- > > http://davsclaus.com @davsclaus > > Camel in Action 2: https://www.manning.com/ibsen2 > > > > -- > Claus Ibsen > ----------------- > http://davsclaus.com @davsclaus > Camel in Action 2: https://www.manning.com/ibsen2 >
