-
Notifications
You must be signed in to change notification settings - Fork 30
Description
I've created a new Grails (2.4.4) project with the routing plugin 1.4.1. I created a simple route but noticed that when I started the app it was starting the camel context but it wasn't auto starting the route ("Skipping starting of route XX as its configured with autoStartup=false").
The route is configured with autoStartup(true). I found that since Camel 2.12.5 if the camel context autoStartup=false then routes won't auto start and instead we have to use startAllRoutes() manually.
In RoutingGrailsPlugin the camelContext is defined with autoStartup:false which is causing the routes to not start automatically.
I would recommend adding startAllRoutes to RoutingGrailsPlugin.doWithDynamicMethods if (config.autoStartup != false). Or put a note up on the home page so new users are aware.
I'm currently starting all routes via Bootstrap.groovy:
def camelContextId = grailsApplication.config.grails.routing.camelContextId
grailsApplication.mainContext.getBean(camelContextId).startAllRoutes()
For more details read - http://camel.465427.n5.nabble.com/migrating-from-Camel-2-13-1-to-2-15-1-suddenly-all-routes-not-starting-td5765551.html