I assume the configure() method is from a class that extends RouteBuilder
On Thu, Jul 14, 2011 at 2:35 PM, Sushmita chandra <[email protected]> wrote: > void configure()throws NumberFormatException { > > > > JndiRegistry jndi=new JndiRegistry() > jndi.bind("XMLCodec",new XMLCodec()) > context = new DefaultCamelContext(jndi.getContext()) > This code should be done *before* you invoke the configure method. It should be done where you create the CamelContext. > from('mina:tcp://0.0.0.0:9091?sync=true&codec=#XMLCodec') > .process(new MinaProcessor()) > .to('direct:inputcsgAdapter'); > } > > -- > View this message in context: > http://camel.465427.n5.nabble.com/For-writing-a-custom-codec-for-Mina-EndPoint-where-should-I-place-the-code-for-registering-with-JNDI-tp4586277p4586493.html > Sent from the Camel - Users mailing list archive at Nabble.com. > -- Claus Ibsen ----------------- FuseSource Email: [email protected] Web: http://fusesource.com Twitter: davsclaus, fusenews Blog: http://davsclaus.blogspot.com/ Author of Camel in Action: http://www.manning.com/ibsen/
