Skip to content

Instantly share code, notes, and snippets.

@uarun
Created November 21, 2011 18:56
Show Gist options
  • Save uarun/1383546 to your computer and use it in GitHub Desktop.
Save uarun/1383546 to your computer and use it in GitHub Desktop.
BeanBuilder definition to scan packages for Camel Routes
import org.apache.camel.CamelContext
import org.apache.camel.processor.interceptor.DefaultTraceFormatter
import org.apache.camel.processor.interceptor.Tracer
beans {
xmlns camel: "http://camel.apache.org/schema/spring"
camelTracer(Tracer) {
traceOutExchanges = true
logLevel = 'INFO'
}
traceFormatter(DefaultTraceFormatter) {
breadCrumbLength = 0
nodeLength = 0
showBreadCrumb = true
showNode = true
showProperties = true
showHeaders = true
showExchangePattern = true
showException = true
showBody = true
showBodyType = true
}
camel.camelContext(id: 'camelContext') {
camel.packageScan {
camel.'package' 'com.mycompany.some.package.with.routes'
// camel.excludes '**.*Nothing*'
// camel.includes '**.*Something*'
}
}
}
beans = {
importBeans 'file:conf/spring/camel-beans.groovy'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment