Willem.Jiang wrote > > The bean method should be thread safe, as the method will be called > from different thread. > The getBean() method is not thread safe:
Just try it out: You need 2 breakpoints in this method: 1. breakpoint at last if in line value = bean 2. breakpoint at line bean = valeu First disable the 2nd breakpoint and start a request so that debugging stops at first breakpoint. The value is a class and the bean is the instance, like it should be. Now enable 2nd breakpoint ans start a second request so that debugging stops at second breakpoint. Step over the bean = value assignement In this thread bean and value are classes now. In the first request the bean has changed to a class, and if you continue you will get the Classcastexception. Willem.Jiang wrote > > BTW the bean DSL support to pass the object, can you use the Object > instead of the Class? > I'll give this a try and let you know. Would be nice if this works. kind regards, Christoph -- View this message in context: http://camel.465427.n5.nabble.com/ClassCastException-using-cxf-bean-tp5599810p5709841.html Sent from the Camel - Users mailing list archive at Nabble.com.