Showing posts from 2019

Camel Endpoint DSL

Camel Endpoint DSL One of the new features of Camel 3.0  is an Endpoint DSL.  This new API aims to provide a type safe replacement for the URLs that are used in Camel to designate the consumer or producer endpoints.  These URLs provide 3 things: the scheme of the URL identifies the component to use, a unique name or id for the endpoint, and a set of parameters to customize the endpoint behavior. Here is an example of an FTP consumer endpoint definition: from( "ftp://foo@myserver?password=secret& recursive=true& ftpClient.dataTimeout=30000& ftpClientConfig.serverLanguageCode=fr" ) .to( "bean:doSomething" ); There are several drawbacks with such constructs : no type safety, bad readability and no simple completion. So we now use the meta model, which is currently extracted from the source using an annotation processor and written in various JSON files, to generate a fluent DSL for each endpoint.  The same

Apache Camel 3.0.0 released !

It's Thanksgiving today and Apache Camel 3.0.0 has just been released, so I definitely want to thank the whole Camel community for the efforts put to get to this important achievement.  The Camel 3 work started a bit more than a year ago , so it's a 14 months effort that reaches its goal today.  But that's definitely not the end, as there's still a lot of work to do on Camel !  One thing to keep in mind is that Camel 2.0 was released in August 2009 , so a bit more than 10 years ago now. Part of this work was cleaning tons of things, components and apis, that were deprecated on this long lived 2.x branch.  Another part was modularization of the code base so that it can be used in more light weight scenarios.  We've created a migration guide to help people migrating their camel based applications.  There are also a lot of new features and we'll explore some of them in the following weeks.  My next blog entry will explore one of this new feature, the endpoint