Hi, thank you for your reply. I tried and it works! thanks a lot..
However i want to know more: it's possible to set the dafault camel namespace without prepending this kind of string? I saw that JAXB gives the possibility to set predefined namespace in a class: this can be done with a package level annotation. Maybe, in this case the RouteDefinition class should be annoteted in this way: @XmlRootElement(name = "route", namespace="http://camel.apache.org/schema/spring/") . public class RouteDefinition extends ProcessorDefinition<RouteDefinition> { If this procedure is wrong or cannot be accepted, maybe we can set the namespace during the node construction process (starting from the string): DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); . factory.*setProperty*( "http://camel.apache.org/schema/spring/"); I haven't tried both the solutions, but i think they are reasonable. -- View this message in context: http://camel.465427.n5.nabble.com/Convert-a-Spring-xml-route-string-in-a-RouteDefinition-tp5746443p5746527.html Sent from the Camel - Users mailing list archive at Nabble.com.