Luca Burgazzoli created CAMEL-13312:
---------------------------------------
Summary: ModelCamelContext
loadRoutesDefinition/loadRestsDefinition are misleading
Key: CAMEL-13312
URL: https://issues.apache.org/jira/browse/CAMEL-13312
Project: Camel
Issue Type: Improvement
Components: camel-core
Reporter: Luca Burgazzoli
Fix For: 3.0.0-M2
We do have method like loadRoutesDefinition and loadRestsDefinition in the
ModelCamelContext interface but they are a little bit misleading as they do not
load a definition in the camel context but they are an helper that invoke
{code}
ModelHelper.loadRoutesDefinition(this, is)
{code}
The only advantage is that you do not need to pass the camel context but other
that that they appear as pure utility.
Toproperly load a route one need to do something something like
{code}
context.addRouteDefinitions(context.loadRoutesDefinition(is).getRoutes())
{code}
which is a little ugly
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)