camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <>
Subject Re: Integration Patterns inside the ActiveMQ Message Broker
Date Thu, 04 Oct 2007 17:47:31 GMT
On 04/10/2007, Nicky Sandhu <> wrote:
> What would be really cool is to write only the routing code as a DSL in Java
> have the container wrap it up in a camel context (either existing or a new
> one)
> E.g. the user would write something like
> from("jms:myqueue").process(xslt("myxslt.xsl")).to("file:mydir");
> and the container would wrap that in a RouteBuilder and add it to a new or
> existing CamelContext.

The thing is, thats not actually Java without the class declaration
:).  To get all the nice IDE completion; we'd need that line inside a
method in a class for a Java IDE.

We could support just the routing as a DSL in groovy or ruby (I've
kinda started some experiments in that direction in the camel-ruby and
camel-groovy modules).

Or we could actually write a real DSL - a very early attempt here:

which has little of the actual Antlr grammar there; but at least it
generates a nice text based editor in eclipse :)

> Ditto for xml config as well.

Yeah, the XML is much easier; we could just allow routes to be
specified in a separate file to the main spring.xml and included.

<!-- routes.xml -->
<routes xmlns="...">
    <from uri="activemq:someQueue"/> <to uri="xmpp:someRoom"/>

<!-- spring.xml -->
<camelContext xmlns="...">
  <import uri="routes.xml"/>

> This would help in separation of roles of a Camel Extender (extends Camel)
> to a Camel User (writes routing rules)

Yeah. In the pure XML world, I can see the separation between system
configuration (data sources, JMS providers etc) with the routing
rules; which may be semi-dynamic at runtime etc.


Open Source SOA

View raw message