On Mon, May 31, 2010 at 6:04 PM, sub3 <[email protected]> wrote: > > > > Claus Ibsen-2 wrote: >> >> On Sun, May 30, 2010 at 9:40 PM, sub3 <[email protected]> wrote: >>> >>> Hi, >>> >>> Can I change the current ThreadPoolProfile maxPoolSize via code at >>> runtime? >>> I wanted to experiment to see if I was hitting the upper limit. >>> >>> I google-d and one person said you could get to it through CamelContext, >>> but >>> I don't see how. >>> >> >> The Camel in Action book explains all about it in great details in chapter >> 10. >> >> You need to obtain the ExecutorServiceStrategy from the CamelContext >> Which is also said on this wiki page >> http://camel.apache.org/threading-model.html >> >> >> >>> Thank for any help, >>> Steve >>> >>> -- >>> View this message in context: >>> http://old.nabble.com/Current-ThreadPoolProfile-tp28724314p28724314.html >>> Sent from the Camel - Users mailing list archive at Nabble.com. >>> >>> >> >> >> >> -- >> Claus Ibsen >> Apache Camel Committer >> >> Author of Camel in Action: http://www.manning.com/ibsen/ >> Open Source Integration: http://fusesource.com >> Blog: http://davsclaus.blogspot.com/ >> Twitter: http://twitter.com/davsclaus >> >> > > Thanks. I read the same thing, but it doesn't help. Yes, I know I need to > get the ExecutorServiceStrategy, but from the javadocs it looks like that is > not possible. Am I missing some indirect way to get that? > --
Quoting from the book: ==================== CONFIGURING DEFAULT THREAD POOL PROFILE You can configure the default thread pool profile from either Java or Spring XML. In Java you access the ThreadPoolProfile from CamelContext. The code below shows how to change the maximum pool size to 50. ExecutorServiceStrategy strategy = context.getExecutorServiceStrategy(); ThreadPoolProfile profile = strategy.getDefaultThreadPoolProfile(); profile.setMaxPoolSize(50); > View this message in context: > http://old.nabble.com/Current-ThreadPoolProfile-tp28724314p28732523.html > Sent from the Camel - Users mailing list archive at Nabble.com. > > -- Claus Ibsen Apache Camel Committer Author of Camel in Action: http://www.manning.com/ibsen/ Open Source Integration: http://fusesource.com Blog: http://davsclaus.blogspot.com/ Twitter: http://twitter.com/davsclaus
