stop
stop plz
Re: OnApplicationEvent not called with CamelAutoConfiguration
Hi, Thanks for the support. I'll note for next version upgrade. -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802p5799363.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: OnApplicationEvent not called with CamelAutoConfiguration
Hi, Tested in a test project and it seems to work. I'll prefer not modifying SpringCamelContext class in my project. Do you have any feedback about my workaround ? Just to know if it is "safe" to use in production or I might encounter other problems. -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802p5799358.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: OnApplicationEvent not called with CamelAutoConfiguration
H, I've tried to use depends-on but failed. >From what I understand of the shutdown process. I think it is related to onApplicationEvent not being called. I've come across this issue[1]. Since ApplicationListener interface has been removed, the method is not called anymore. Its only called by CamelContextFactoryBean but it's not the case when using Spring-boot. Here is what I'm using as a fix [2] [1] https://issues.apache.org/jira/browse/CAMEL-2607 [2] @Component public class SpringCamelContextFix implements ApplicationListener { @Inject private SpringCamelContext camelContext; @Override public void onApplicationEvent(ApplicationEvent event) { camelContext.onApplicationEvent(event); } } -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802p5799276.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: OnApplicationEvent not called with CamelAutoConfiguration
So its not a bug in the SpringCamelContext handled by CamelAutoConfiguration ? What you are saying is that its not related to the onApplicationEvent method and the shutdownEager ? I'm lost really thought it was that and calling it was fixing it though ... -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802p5799249.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: OnApplicationEvent not called with CamelAutoConfiguration
Hi, When I shutdown the application with at least 1 inflight exchange I get the following logs : 2017-05-04 18:21:59.748 WARN 12188 --- [er[test.queue]] o.a.activemq.jms.pool.PooledSession : Caught exception trying rollback() when putting session back into the pool, will invalidate. javax.jms.IllegalStateException: The Session is closed After some investigation via breakpoints. On shutdown the ConnectionFactory.stop() method is called before the CamelContext is shutdown. After more investigation, SpringCamelContext has a method called "onApplicationEvent" which is handling the spring shutdown. But this method is never called. Is that normal ? When I create a @Component which @Inject SpringCamelContext and call it manually it works. -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802p5799221.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: OnApplicationEvent not called with CamelAutoConfiguration
Hi, Anyone can confirm or infirm this ? Is there a way to create an issue if it is confirmed ? Can someone help me to get a good temp fix for this or valid that what I'm doing is correct ? Thanks -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802p5799162.html Sent from the Camel - Users mailing list archive at Nabble.com.
OnApplicationEvent not called with CamelAutoConfiguration
Hi, I'm using SpringBoot with camel 1.4.3.RELEASE 2.18.3 CamelContext is auto configured via : CamelAutoConfiguration If I understand correctly the SpringCamelContext is instancied via CamelAutoConfiguration class and not by CamelContextFactoryBean. Since https://issues.apache.org/jira/browse/CAMEL-2607, the SpringCamelContext doesn't implement ApplicationListener interface anymore. It seems like onApplicationEvent is not called on the SpringCamelContext which in my situation cause the AMQ ConnectionFactory to be destroyed before the camel graceful shutdown. Anyone has this issue or can confirm ? Has a fix, I created a component which is listening ApplicationEvent and forwarding them to injected SpringCamelContext. Thanks -- View this message in context: http://camel.465427.n5.nabble.com/OnApplicationEvent-not-called-with-CamelAutoConfiguration-tp5798802.html Sent from the Camel - Users mailing list archive at Nabble.com.
SpringCamelContext onApplicationEvent not called with SpringBoot
Hi, I'm using SpringBoot with camel 1.4.3.RELEASE 2.18.3 CamelContext is auto configured via : CamelAutoConfiguration If I understand correctly the SpringCamelContext is instancied via CamelAutoConfiguration class and not by CamelContextFactoryBean. Since https://issues.apache.org/jira/browse/CAMEL-2607, the SpringCamelContext doesn't implement ApplicationListener interface anymore. It seems like onApplicationEvent is not called on the SpringCamelContext which in my situation cause the AMQ ConnectionFactory to be destroyed before the camel graceful shutdown. -- View this message in context: http://camel.465427.n5.nabble.com/SpringCamelContext-onApplicationEvent-not-called-with-SpringBoot-tp5798755.html Sent from the Camel - Users mailing list archive at Nabble.com.