camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <>
Subject Johan, it happens for all committers
Date Fri, 17 Dec 2010 18:15:13 GMT
That you commit something which you shouldn't have done.

Today it was Johan's Ed. first time he did that. Welcome to the club.
I am the president, I must have committed the most bad commits to
Camel :)

Your little change in the route model (FromDefinition) really got me
puzzled today.

I have been working on a bigger improvement and have changed files in
core, core-xml, spring. And suddenly I got unit test failures in
I wondered why because the commits today have been simple and not in
that area. And the CI servers have been busy with other projects and
haven't got around testing the latest commits from trunk. So I
couldn't see the test failures there.

Anyway I digged into it, and almost had me wished I have switched to
git, so I can do a stach. Yeah I will switch later. Writing a book
took all my time.
Then I remembered your commit. The problem is that the route model
must be stateless and agnostic, eg not tied to a runtime CamelContext.
You can use the route model to create runtime routes, and thus it can
act as a skeleton.

So in your change you introduced state as it remembered the endpoint
you would lookup at runtime. But the problem is that you could have it
lookup endpoints from CamelContext A and then use the route model to
create a new runtime route in another camel context or whatever. Then
that endpoint is no looked up in CamelContext B, but it will just use
the existing it previous looked up from CamelContext A.

For example using the routeContext in XML.

You may consider buying a beer when we meet. My wife got a bit cranky
because I was occupied digging into this issue,
than talking with her when she came home from work.

Anyway welcome to the club.

I actually wrote this as a reminder to us all about the route model
must be stateless. The mistake here could be done by any of us, so
there are no hard feelings. Just that it took me for a little ride,
which doesn't happend that often anymore with Camel. (Well except
crappy and mysterious issues with osgi, but that's another story for
all of us).

Claus Ibsen
Twitter: davsclaus
Author of Camel in Action:

View raw message