Tag Archives: maven

Configure camel -openwebbeans – deltaspike to get a standalone camel application running with cdi

here are code snippet to get camel, OpenWebBeans container and deltaspike .

  • The code that boots the app
  org.apache.camel.cdi.Main maincdi = new org.apache.camel.cdi.Main(){};
  maincdi.run();
  • camel context producer
public class CamelContextFactory {

    @Produces
    @ApplicationScoped
    CamelContext customize() {
        DefaultCamelContext context = new DefaultCamelContext();
        context.setName("my-custom-camel-context");
        return context;
    }

    void cleanUp(@Disposes CamelContext context) {
        // ...
    }
}

Continue reading Configure camel -openwebbeans – deltaspike to get a standalone camel application running with cdi