camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen (JIRA)" <j...@apache.org>
Subject [jira] Created: (CAMEL-3378) Make it easier to load routes from XML files using a method from CamelContext
Date Mon, 29 Nov 2010 13:03:37 GMT
Make it easier to load routes from XML files using a method from CamelContext
-----------------------------------------------------------------------------

                 Key: CAMEL-3378
                 URL: https://issues.apache.org/jira/browse/CAMEL-3378
             Project: Apache Camel
          Issue Type: Improvement
          Components: camel-core
    Affects Versions: 2.5.0
            Reporter: Claus Ibsen
            Assignee: Claus Ibsen
            Priority: Minor
             Fix For: 2.6.0


Currently you got to battle with JAXB to do this. But we should add method to do this in few
lines of code.

{code}
        InputStream is = getClass().getResourceAsStream("barRoute.xml");
        RoutesDefinition routes = context.loadRoutesDefinition(is);
        context.addRouteDefinitions(routes.getRoutes());
{code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message