2013-11-20

Happy Birthday hawtio - 1 year old today

Today its exactly 1 year ago hawtio came to live, when its creator James Strachan pushed the first commit to its home at github.
commit 3d46cb025e80feeec0b32bbe1898848235a8d6d7
Author: James Strachan
Date:   Tue Nov 20 22:30:13 2012 -0800
    Initial commit
hawtio was created 1 year ago, and its flaming logo is maybe inspiration for its hot name?

So 1 year after the first commit, we have 3014 commits at this time of writing, by 23 contributors, and there has been 29 release. Well we have gone a bit mad with milestone releases for the 1.2 release, where the last is 1.2-M27.

The project wouldn't be so awesome today if it was not for all the contributors besides James Strachan itself. For example Stan Lewis is the CSS/HTML5 ninja that can make the UI look good and actually work in our browsers. Andreas Gies and David Bosschaert loves OSGi so they contributed and improved the OSGi and Karaf plugins. And with the help of the other 20 or so contributors, we have today more than 25 plugins out of the box.

We also likely have one of the most creative tagline for the project, as you can see from the hawio front page.

Don't cha wish your console was hawt like me? I'm hawt so you can stay cool

What's up with the upcoming 1.2 release?

The hawtio team is busy working on the upcoming 1.2 release. A lot has happenedFor e since the 1.1 release from April 2013. We are almost there, and a new release is expected out later this year.

I am currently working on improving the plugin documentation which is available both online from the hawtio itself, by clicking the ? button on your top right corner, and as well from the plugins page. You can see each plugin's documentation by clicking on the plugin name. The documentation on the website is the same documentation as in the online help.

Having better plugin documentation helps new users better understand how to use the plugins, and also allows new users to read about the plugins at the website. For example the Camel plugin has a lot of great eye candy showing its debugger, profiler and whatnot in action.


Happy Birthday

Happy Birthday hawtio - you are an amazing project, giving live to so many projects

James scored a hattrick, creating all of these amazing open source projects


... all projects are ASL2 licensed ;)


Trying hawtio

If you want to try hawtio in action yourself, then its easy, just follow our getting started guide.

2013-11-06

Developer of the week - DZone Interview with me published

I was recently contacted by DZone for a little interview to appear on their developer of the week.

So today my interview was published at http://java.dzone.com/articles/dev-week-claus-ibsen.

Developer of the week interview of me at DZone published this week
Just wanted to post this blog, so I remember when it happened and have a link to the interview.

PS: If you notice, then I had to cut the image above in 2 pieces, to cutout an advert from a dubious company that is in the 'donkey' business. 

2013-10-26

A new book - Instant Apache Camel Messaging System

Its great to see the Camel community goes from strength to strength over the years. And this year there is three new books being published.

One of the books is titled - Instant Apache Camel Messaging System, by Evgeniy Sharapov. Published by Packt publishing in September 2013.


This week I had the pleasure of reading the book. Its a short book with 78 pages (111 on my iPad mini) and I was able to read it in two evenings. I enjoyed reading the book as it was well written, the english language and grammar is spot on, and there is a "red line" that takes you through the content, with nice transitions from one section to the next.

This book covers the following topics
  1. What is Apache Camel
  2. Installation
  3. Quickstart creating your first Camel project
  4. Top 6 features
  5. Where to find more information in the community

Ad 1 - What is Apache Camel

The book explains what Apache Camel is in 4 pages. It is a good attempt, but I would liked to see more details, and a figure to better explains the relationship with Camel, Components, Routes, and EIPs.

Ad 2 - Installation

Installing Apache Camel is focused primary on using Apache Maven as the built tool, and this book, covers how to create a new generic Maven project from the command line, and then how to add Camel dependencies, and prepare the project for Eclipse or IDEA editors. Though the author also covers how to manually download and unzip the Apache Camel distribution and how to add JARs to your project.
Along the way in the book there is small screenshots of the example project structure and code listings of the Maven pom.xml file and other important pieces to highlight. The author has done a great job striking a balance to the reader so he can easily follow what is going on. I really like its the same example that is used throughout the book, and is being modified on the way, as Camel's functionality is unlocked.
I would have liked to see how to create new projects without the command-line such as from the wizards built-in Eclipse. That is easier today as Maven is provided out of the box in Eclipse.

Also mentioning about the Camel Maven archetypes would have been good. 

Ad 3 - Quickstart

In the quickstart chapter we develop a small Camel application that logs a message to the logger, using a Camel route. The content is good and I like there is a screenshot figure of running the application, which shows the reader what happens.

The book also goes a bit deeper explaining what CamelContext, and RouteBuilder is. And how the quickstart application works. 

Ad 4 - Top 6 features

This chapter is covering 6 must-know features - though unfortunately the author does not summarize which 6 features that would be. 

What is covered is:
- Some Camel concepts such what is a Message / Exchange
- Using Camel Main support
- Testing Camel applications with and without Spring
- Routing with Java and XML DSL
- Transformations
- and very briefly talks about EIPs (frankly to short)

This is the big and main chapter of the book, that uses the same example which we then add functionality on the way - this is very good. Later in the chapter a new real-life example is being covered about custom document declarations. This is a very good example, and the reader learns how to use content based routing, xpath and java predicates, xslt transformation, using JAXB, and how to write Camel type converters, and a little bit about JMS, and how to put  that together and unit test as well. The reader is also shown how to build unit tests, and touching how to advice the routes during testing to mock/replace parts making unit testing in isolation easier.

There is a few minor information that could have been updated. When you write a custom Camel type converter, you should use the fully qualified classname of the type converter classes in the META-INF/.../TypeConverter file. This is what we recommend.
Also writing a custom type converter for XML -> your JAXB object is not needed as just use camel-jaxb and include the jaxb.index file and Camel has a fallback type converter built-in that does this out of the box.

All together a great example that shows more of Camel powers at the time, when the reader is ready to learn more. Very well done by the author.

Ad 5 - More information

The book ends with some details where to find more information, such as other books, and online material on other web sites, user forums such as stackoverflow, and Camel bloggers.

A nice touch but I would have liked to see a bit more detail, as the Camel community is vast, and there is a lot of information out there.


Summary

This is a great book for new users to Apache Camel, who are looking for practical examples how to get started using Apache Camel, who may not be able to find such information in one place. All the information you need to get started with Camel is there at your fingertips, but you have to be prepared for being practical and try the source code of the book. This book is not for experience Camel users, whom already have built a couple of Camel applications.

After reading this book you will be much better prepared to be successful and be able to learn more and use Apache Camel in your day time job.

The information in the book can be found freely available on the internet today, but you will need to jump between content and that would take you a much longer time, than it would be to just purchase this eBook and in a few days be prepared for working with Apache Camel.

The title of the book is misleading, I blame the publisher, for not taking the title serious. There is another book that hit the market with a similar scope and title. Readers are being mislead. This book doesn't cover messaging. Its a beginner/introductory book. Use that in the title! It seems the publisher takes some integration like words and put together at random. What if the title was: Instant Concise Application Messaging Exchange Language (hint) - that would be confusing as well.

A IMHO better title could have been using words like:
  • Get started with Apache Camel
  • Learning Apache Camel
  • Practical Apache Camel 
  • Beginning Apache Camel
Though possible could be more creative with the title, and maybe something like: Instant learn using Apache Camel in 2 days.

Okay besides the title, the book is only for new users, but its a great book.

Rating: **** (4 out of 5) based on being a highlight practical book for new Camel users, that is easy and fun to read. After reading the book you have a feeling to learn more, and wished the book had more pages. 

What's next

Along the way you may want to read these freely available information as well. They explain what Apache Camel is in more detail, and also goes more in deep with the Camel concepts with is important to know. 


If you intended to go on using Apache Camel, then you may want to pickup another books that goes much more in depth what Apache Camel can do. Today on the market there is:

- Apache Camel developers handbook (to be published later this year)

Disclaimer: I am co-author of the Camel in Action book.

And I end this blog by congratulating Evgeniy Sharapov for authoring a great Apache Camel beginner book, that is a joy to read. You sure have flair and talent for writing. Hope this is not the last book from your hands.



2013-10-22

Apache ActiveMQ 5.9 released

The Apache ActiveMQ team has just released the new ActiveMQ 5.9 release.

Apache ActiveMQ 5.9 released
This release is 8 months of hard work since the previous 5.8 release.

In this release we have as usual more hardening of the broker, and the recent new protocols such as AMQP and MQTT. Also very interesting is the hardening of the leveldb persistent store, which now also includes a new replication functionality. Over time level db is planned to be default out of the box persistent store, instead of the current kahadb store. Though we are not there yet, so kahadb is still the default store.

Another great new functionality is the ability to do runtime configuration changes to the broker without having to restart the broker. You cannot change everything yet, but you can for example update network connectors when you have clustered brokers etc. The documentation details which parts can be updated.

For the Camel users then there is a new broker component which allows lighter inter broker routing. Rob Davies have previously blogged about that, and provides an interesting use-case which allows to use Camel routing logic to decide if sending a message to a queue should go into the queue, or to another queue, depending on the current queue depth.

Last but not least Apache ActiveMQ now ships with hawtio as its new web console out of the box. The old web console is still there, but is considered deprecated.

We also cleaned up in the conf directory, moving all the example configurations into examples/conf.

Apache ActiveMQ 5.9 release notes is here.

Starting Apache ActiveMQ

To try out Apache ActiveMQ is easy. You go to the activemq.apache.org web site and click the download link. Then you can download a zip or tgz file of the distribution. Then you unzip/untar the file and then you can start the broker from the command line as shown below

davsclaus:/opt$ tar xf ~/Downloads/apache-activemq-5.9.0-bin.tar.gz
davsclaus:/opt$ cd apache-activemq-5.9.0/
davsclaus:/opt/apache-activemq-5.9.0$ bin/activemq console

When the broker is staring up it now logs all the transport connectors it provides and their urls.
From the logs below we can see that ...

 INFO | Listening for connections at: tcp://davsclaus.air:61616?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector openwire started
 INFO | Listening for connections at: amqp://davsclaus.air:5672?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector amqp started
 INFO | Listening for connections at: stomp://davsclaus.air:61613?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector stomp started
 INFO | Listening for connections at: mqtt://davsclaus.air:1883?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector mqtt started
 INFO | Listening for connections at ws://davsclaus.air:61614?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector ws started

we have the following transport connections enabled

  • openwire - is the JMS protocol
  • amqp - AMQP 1.0
  • stomp - is a very simple text based protocol, you can use from telnet 
  • mqtt - for machine to machine communication
  • ws - websocket (stomp or mqtt)

Telnet to the broker

For example with stomp we can connect to the broker using telnet, and type in the telnet shell stomp commands to connect, send and receive messages. For example to connect i can type

telnet localhost 61613
CONNECT
login:foo
passcode:bar

^@

And the broker will response with

CONNECTED
heart-beat:0,0
session:ID:davsclaus.air-61798-1382433481104-2:1
server:ActiveMQ/5.9.0
version:1.0

And I can then disconnect with

DISCONNECT

^@
Connection closed by foreign host.

There is a user guide here how to use telnet with stomp.

Accessing the web console

When ActiveMQ broker starts up it logs the url for the web console(s)
 INFO | ActiveMQ WebConsole available at http://localhost:8161/

So just open a broker on that link. When you access the console its secured, so you need to login. The broker comes with a default user and password, which you can see in the conf/users.properties file.

There is also a docs/WebConsole-README.txt file that provides more details about the web-consoles, and how you can turn on|off login etc.

For example with hawtio web console we can create queues, and send messages to the queues. In the screenshot below I have created two queues: beer and wine, and send a message to the beer.
hawtio web console - comes out of the box in the new Apache ActiveMQ 5.9 release.
The console has actions to move messages between queues, browse, and delete. And messages in dead letter queues, can be resubmitted to their original queue, which allows to retry processing the message(s).


Trying the ActiveMQ web examples

Apache ActiveMQ comes with a few web examples you can try by starting the broker as follows
bin/activemq console xbean:examples/conf/activemq-demo.xml

To try the examples then open the web browser at http://localhost:8161/ and click on the last link. PS you should also try clicking on the web console link (hawtio) as the web console now also shows the Camel plugin, as one of the examples is using Camel.



2013-10-11

Sneak peak of JBoss Fuse 6.1

Yesterday James Strachan blogged about some of the stuff the fuse team has hacked on this year, which is included in the upcoming JBoss Fuse 6.1 release, due out at the end of this year.

James doesn't blog as often, so when he does, its really worthwhile the read.

Just an eye candy screenshot here about one of the new functionalities that James talk about - ActiveMQ topologies. This functionality is the latest to the game, and was created after the Fuse team had a face to face in Dublin 2 weeks back.

ActiveMQ broker topologies in Fuse Management Console (hawtio branded)
The web console from the screenshot is a Red Hat JBoss branded hawtio, its the same code and plugins underneath as you have in the hawtio project. Anyone can customize and do their own branding in hawtio - how hawti is that :)

So if you want to see more eye candy and read what's coming then read what James blogged.

Mind that this is just some of the stuff included, there is even more to come - for example a Camel data mapping tool, and log analytics is yet to be polished a bit more.

Later this month a beta release of JBoss Fuse 6.1 is expected to hit the streets, then you can try this out yourself. If not we have daily EA builds that (sometimes is broken), you can try as well.

And you can catch the fuse team on IRC, if you want instant help or wanna chat via #fusefabric on irc.freenode.net.

2013-09-16

Hawt new web console for Apache ActiveMQ

Recently ActiveMQ committer Christian Posta blogged about how to use hawtio as the web console for Apache ActiveMQ.

Hawtio is the brand new awesome web console that will be replace the old clunky web console from Apache ActiveMQ 5.9 onwards.

Hawtio web console for Apache ActiveMQ from the video Christian Posta recorded.
I have previously blogged about hawtio and talked about some of the cool stuff it can do for Apache Camel, and the cloud as well.

Now Christian did a video recording of hawtio and ActiveMQ in action. So if you are curious to know more about this, you can grab a cup of coffee and enjoy the 20 minute video.


2013-09-15

Apache Camel 2.12 Released

A week ago Apache Camel 2.12 was released.

Beware - Apache Camel 2.12 has been released. And its faster than ever!
As this release is yet another great release I wanted to write a blog post to highlight and spread the word of this release.

My intention was to write the blog sooner, but I have a keyboard problem with my laptop, where some keys type double, which makes the keyboard unusable. So I have to plugin an external keyboard, and thus I am limited to using my computer in the office, and not carry it around with me.

Celebrating the 53rd release
Okay excuses aside. Back to the Apache Camel 2.12 release. This release is in fact the 53th release according to Maven Central.

And its my 50th release of Apache Camel, as Apache Camel 1.3 was the first release where I was onboard the Camel team as a committer. And Camel 1.0, 1.1, and 1.2 was the 3 preceding releases.

A kick-ass community
The Apache Camel community is fantastic. Its only been 4.5 months since we released the Apache Camel 2.11.0 release. So with 4.5 months of hacking and development the Camel community have contributed and added

- 17 new components
- 4 new examples
- improved performance in simple/bean languages and routing in general
- resolved more than 300+ JIRA tickets
- fixed many bugs and added many improvements

About half of these components has been donated by contributors, and the remainder by developers from the Camel team. A good and health mix.

First step to generate and include component documentation
This is the first release where we have taken the first steps to allow Camel components to provide documentation in the source code which gets generated and included in the binaries. Likewise a Camel component can offer endpoint completion which allows tooling to offer smart completion. For example the hawtio web console uses this to allow people to have auto completion for JMS queue names, file directory names, bean names in the registry and whatnot.

Other great improvements
There is a number of other improvements that Willem Jiang already blogged about here. I have taken the liberty of quoting some of his highlights, which I find the most interesting, here:
Reduced stack-frames in use during routing, that also makes Camel's stack traces being logged much less verbose. This also allows people to easier debug the internals of Camel as less AsyncCallback callbacks are in use during routing. This also has an impact on improving routing performance, with smaller thread-frames in use. I have previously blogged about this - long stacktraces in Apache Camel no more.
Easy to use Message History out of the box. And included message history as "route stack-trace" when exceptions logged by Error Handler to make it easier for end users to spot where the exception occurred. 
Stream caching configuration become easier by using StreamCachingStrategy which allows spool directory per Camel Context instead of shared per JVM. Likewise you can setup to only spool to disk when running low on memory. And you can see the stream insight at run time by using JMX management. 
Polling Consumers such as File, and FTP now supports using custom scheduler. Providing a new Quartz2, and Spring based out of the box, that allows to use CRON based scheduler. Which I have previously blogged about - even easier cron scheduled routes.
And other great new improvements is that you can configure the scheduled consumers to be less aggressive when there is no data to poll. This avoids taking up resources in times where there is no data anyway to process. I have previously blogged about this - backoff support for less aggressive polling routes.

POJO aggregation strategy - Yeah we finally implemented that!
And finally you can now develop aggregation strategy implementations as pure POJO classes without having to implement the org.apache.camel.processor.aggregate.AggregationStrategy interface. Just developer a POJO with a method, and have parameters accordingly to a convention. Unforunately I didn't find time to blog about it, but I did add extensive documentation about this at the Camel aggregate EIP pattern. Notice that this works for any of the EIPs that supports AggregationStrategy, such as Content Enricher, Multicast, Recipient List, Splitter etc.

Facebook and more social on the way
And for the people asking for social components, we have new components for Yammer and Facebook. And we also have geo location and a weather component. For the upcoming Camel 2.13 we plan to add support for linkedin. As usual we love contributions so if anyone want to help up, then the community loves that.

And the small things that makes a wonder for some people ...
And a little but great detail is that you can now hide sensitive information, such as passwords in JMX by turning on the mask option. For example you may have staff that manages your Camel application using JMX and you do not want them to be able to read passwords.

More details
You can find more details in the Camel release notes.
And also from Willem Jiang blog.

2013-08-28

Video presentation - Connecting Applications Everywhere with ActiveMQ

This morning while having my morning coffee I watched this video presentation on my iPad.

Connecting Applications Everywhere with ActiveMQ / JBoss A-MQ
Its a 45 minute presentation by Rob Davies, whom is also working in the JBoss Fuse team. In Rob's talk he gives a run down of ActiveMQ and JBoss A-MQ, and how its multi protocol support enables the internet of things, and connecting anything together. In the last 10-15 minutes of the talk, Rob dives a live demo (see screenshot), where he is using a micro controller to capture the sound and send the data over wifi to his laptop using MQTT and then bridging over AMPQ, and then eventually to a HTML5 client using web-socket. 

A really good presentation and demo. It was a great start of my day watching this presentation.
If you notice from the demo then Rob uses the Apache ActiveMQ 5.8.0 release out of the box. 

The video is available from dzone and you can watch it without registration or any kind of hazzle.






2013-08-21

Apache Camel 2.12 - Backoff support for less aggressive polling routes

This is another blog post about some upcoming improvements and new features in the next Apache Camel 2.12 release.

In the last blog I spoke about cron expressions directly supported in the routes. This blog post is related as we have another new feature to the polling routes (using scheduled polling consumers).

The scheduled polling routes will by default poll for new messages at a fixed rate (usually every half second). Though in some use-cases new messages does not arrive evenly spread over the day, but may tend to arrive in batches. So during the times where there is no new messages arriving, the scheduled polling consumer, would not pickup new messages, but still keep looking for new messages at the same pace.

So what we have introduced is a backoff that allows you to let the scheduled polling consumer check less aggressive when there is no messages.

To support that we have introduce 3 new options


  1. backoffMultiplier = To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured.
  2. backoffIdleThreshold = The number of subsequent idle polls that should happen before the backoffMultipler should kick-in.
  3. backoffErrorThreshold = The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in.

The scheduled Polling Consumer is by default static by using the same poll frequency whether or not there is messages to pickup or not. From Camel 2.12 onwards you can configure the scheduled Polling Consumer to be more dynamic by using backoff. This allows the scheduler to skip N number of polls when it becomes idle, or there has been X number of errors in a row. See more details in the table above for the backoffXXX options.

For example to let a FTP consumer backoff if its becoming idle for a while you can do:

from("ftp://myserver?username=foo&passowrd=secret
      ?delete=true&delay=5s
      &backoffMultiplier=6&backoffIdleThreshold=5")
  .to("bean:processFile");

In this example, the FTP consumer will poll for new FTP files every 5th second. But if it has been idle for 5 attempts in a row, then it will backoff using a multiplier of 6, which means it will now poll every 5 x 6 = 30th second instead. When the consumer eventually pickup a file, then the backoff will reset, and the consumer will go back and poll every 5th second again.

In JMX you can see whether the backoff has kick-in, as the consumer would have the attribute backoffCounter > 0.

You can find more details at

2013-08-15

Apache Camel 2.12 - Even easier cron scheduled routes

In the upcoming Apache Camel 2.12 we have recently introduced a SPI that allows to plugin different schedulers for scheduled based consumers.

So the motivation is that some Camel components has scheduled consumers, most know is the file and ftp consumers. By default they use the scheduler from the JVM that can schedule based on a fixed period. Though with the SPI we now allows a different scheduler to be used instead.

We have two cron based schedulers ready out of the box in the camel-quartz2 and camel-spring components. So you pick you favorite, or dive in and build your own scheduler.

CRON expression
So if you want to pickup files during working hours (polling every 10th second) on weekdays you can easily do this now (notice we use + as space separator)

... with Spring

<route>
<from uri="file:inbox?scheduler=spring&scheduler.cron=0/10+6-18+*+*+MON-FRI"/>
...

... with Quartz

<route>
<from uri="file:inbox?scheduler=quartz2&scheduler.cron=0/10+6-18+*+*+MON-FRI"/>
...

In older releases of Camel you would need to sort to use a route policy, to implement a similar solution. There is a cron based route policy that can be used to setup cron expressions when a route should be started, and when it should be stopped. Though with this new functionality in Camel 2.12, its even easier to just define the cron expression in the endpoint uri directly.

There is more details in the Camel docs at

And yeah camel-quartz2 is also a new component in the upcoming Apache Camel 2.12 release. In fact we have already 14 new components. You can peak at the work in progress release notes to see what is coming down the road.

2013-08-02

Apache ServiceMix How-to book published

A few months ago a new book hit the market.

Apache ServiceMix book, recently published. Authored by Henryk Konsek.
Apache ServiceMix Hot-to, authored by Henryk Konsek, who is also a Apache Camel committer.

First I want to congratulate Henryk for being published - welcome to the club. I received my hardcopy of the book a couple of weeks ago. My part of this book was helping Henryk being a reviewer.

The book is a practical how-to book with 19 recipes for using and working with Apache ServiceMix. Starting how to install and start ServiceMix, and showing how the shell and web-console works, as well how to access the logs, install applications and the likes. And then covering some examples how to develop and deploy Camel and CXF based applications.

The book is great for new and intermediate users of Apache ServiceMix. Users with many years of ServiceMix knowledge would surely already know most of the content of the book.

And you can read the book over a weekend, its 53 pages.

2013-06-17

Introducing the new Apache Camel based iPaaS

I just got back from CamelOne 2013 which was the 3rd annual Camel conference.

At the conference, James Strachan, introduced the new open source Apache Camel based iPaaS at the ending keynote on the first day.

You can find more details from James blog where he put out this information with the slides and a cool 20 minute video demonstrating the iPaaS in action. Its all a single page HTML5 web console, using the awesome hawio project.

In the video you will also see cool stuff such as the new Camel visual debugger, where you can set breakpoints, and single step the message in the routes etc.

And we also reveal for the first time the new web UI for log analytics (insight search). So you easily search in the logs from all the containers, and correlate the log messages, and have all that visualized with timeline, graphs etc.

I guess a few screenshot is worth a 1000 words in this case.

Lets start with the new insight plugin in action ...

Fabric Insight in action - Live log analytics using Kibana web UI, to aggregate and visualize log from all your containers. Notice the Camel tab with first class Camel integration.

And the debugger in action ...

Camel debugger in action - Live debugging of Camel routes, set breakpoint, single step, see message details. And as well edit the message on the fly (to be added)

And we also got time to add a new Camel route creator / editor that is purely web based ...

Camel route designer - A full Camel editor in the web console with wizards, making it easier for casual Camel developers to use.
Though the video shows all this in action, and there is a funky theme song to go along. The selection of the song was done after careful consideration in the bar, after a long day at CamelOne ;)

To see the video I suggest to click this link to get to James blog, or use this link for the direct link to Vimeo where the video is hosted.

On James blog you will also find instructions how to run this from the source code and try this on your own.
Fuse Fabric and hawtio are both 100% open source projects, with the ASL 2.0 license, and their source code hosted on github. We love contributions and collaboration. So feel free to fork and send pull requests. And if you send too many, then you can become a member of these projects, and commit directly ;)


2013-06-03

See you soon at CamelOne 2013

So CamelOne 2013 is starting on sunday evening with a reception with drinks and beers. What a great way to start. You can find details when and where at the agenda from the website. So make sure to attend on sunday evening if you can.


The conference then follows on monday and tuesday. The full agenda is up on the website at

This is the 3rd annual CamelOne conference, which is focused on the Apache integration projects such as Apache Camel, ActiveMQ, ServiceMix, Karaf and CXF. The speakers at the conference includes the founders of these projects, leaders, committers, long term end users, book authors, and as well end users who are using these projects in their companies.

We have a mix of speakers who are the people who hack on the projects all day long, and as well people who have used these projects in large projects at their companies. So you get information from both sides of the fence.

Rob Davies have blogged about what to look forward to at the conference. And as well giving a teaser for his talk about connecting applications everywhere with ActiveMQ.

Christian Posta who has dived deep into the internal of ActiveMQ is giving a talk about ... well the internals of ActiveMQ.

I will give a getting started with Apache Camel presentation, which is aimed for beginners or new users of Camel. And on the 2nd day I give a rundown of the common Camel components, and as well how to build your custom components. Both my talks is a mix with slides and practical live coding sessions.

I am much looking forward to James Strachan's ending keynote on the first day about using the hawtio web console with Apache Camel. There is gonna be some cool stuff revealed for the first time :)


2013-05-29

Long stacktraces in Apache Camel no more

In the upcoming Apache Camel 2.12 we have improved the internal routing engine to dramatically reduce the stacktraces, our end users will see when an exception occurred and was logged.

During the development of the improvement we had a small sample route for benchmarking.
It was basically a simple route with:

from("seda:start")
  .to("log:foo")
  .to("log:bar")
  .to("log:baz")
  .process(new Processor ...);

And in the processor we forced an exception being logged. In Apache Camel 2.11.x the stacktrace would be around 40 lines. The Camel team managed to reduce this down to 15 lines. And the bottom 6 lines is 3 from the JVM and 3 from the seda consumer. So in between the routing engine is executing; and that's where we have optimized the code. So we went from (40-6 = 34) to (15-6 = 9). Eg before we had 34 lines during the routing, and that is down to 9 now.

Camel is still executing the same functionality. As an end user there is no functionality turned off or missing now. Its all still there and being executed; just in a different way. What we did was refactor most of the internal cross cutting functionality into a single entity CamelInternalProcessor (name subject for change), and fold that into a single stack-frame being executed.

This improvement is internal changes only, and all end users Camel application is upgrade compatible.

For our end users who have been debugging the Camel source code, this is now also simpler, as we added code comments in the CamelInternalProcessor with pointers how to do this easier, and which part you can safely skip over, to make your debugging experience easier and faster.
And speaking of debugger. Then we also added a new BacklogDebugger, which is a Camel routing debugger JMX MBean which is ready to use for tooling and end users. For example you can use it easily set breakpoints, single step a message in the routes, and edit/view its message content. Now for the graphical UI, then James Strachan is hacking on hawtio to add this in the upcoming hawtio 1.2 release. And since its JMX based you can always use it from a JMX console such as JConsole or JVisualVM. And for the brave a plugin to Eclipse / IDEA could be developed to integrate it with their native debugger; but thats a big task to take on.
For further details and background on the stacktrace improvement then you can take a look at the ticket CAMEL-6077 and our discussion on the Camel developer mailing list. As well we have a sample of the before and after stacktraces in the CAMEL-6077 ticket.

2013-05-13

Webinar on May 16th 2013 - Using Apache Camel connectors for external connectivity

I have the pleasure of speaking at a webinar on thursday focusing on Apache Camel components.

Webinar about Apache Camel components
Any integration requires connectivity to applications, services, or databases. Connectivity could be a file drop via FTPor sFTP, a JDBC call to a database, or a webService call to an application. Apache Camel comes with 100+s Camel components or connectors that enable this functionality.

To archive that Apache Camel comes with 130+ components out of the box, ready for you to use. In this webinar we take a look at some of the popular components, as well how you can write your custom components.

The webinar is a mix between slides and live demonstration. The session is scheduled for one hour, where we leave about 10 minutes at the end for Q and A.

Register for this webinar and learn how:
  • Apache Camel speeds connectivity.
  • To use Apache Camel components to create faster integration solutions.
  • To build custom Camel components.

When
Thursday, May 16, 2013 at:
  • 15:00 UTC
  • 11:00 am (New York)
  • 4:00 pm (Paris)
  • 8:30 pm (Mumbai)

How to register
The webinar is free and you can register for the event from this link.

2013-05-10

Video recordings (in Danish) from my latest getting started with Apache Camel presentation

Last week I visited Ã…rhus, Denmark to give a presentation about Apache Camel. This event was organized by JavaGruppen, and OpenMinds was kind to host the event, in their beautiful office centrally located in Ã…rhus.

Thanks to Thomas Salling whom was so kind to pick me up at the train station, I arrived safely and in time for the event.

Claus presenting Apache Camel at Javagruppen meeting in Ã…rhus, Denmark -  Photo by Søren Glasius
At the event we had a great turnup, of about 25 people. And we were almost out of free chairs, and space in the room, as you can see from the photos.
Attendees at the event - Photo by Søren Glasius
After the event we went for beers at Sct. Clements which is a brewery inside the restaurant.
Having beers at Sct Clemens after the event.
My presentation was 2 hours and with a mix of slides and live demonstrations. And as well taking in questions. We had a 10 minutes break at the one hour mark. Giving such a long presentation is of course a challenge. The response from the attendees was positive and they didn't get bored etc. And we had about 2/3 of the attendees whom didn't know about Apache Camel.

I also had the pleasure of meeting with two former colleagues whom I haven't seen in over 10 years. It was great to see you Michael and Simon.

Søren Berg Glasius, whom is known in the Groovy and Grails communities  is head of organizing the GR8Conf conferences. The next GR8Conf takes place in a couple of weeks in Copenhagen, Denmark. So he is testing his video and presentation equipment, so we used this opportunity to video tape my entire presentation. Unfortunately there was some problems with the HDMI connection so we had to settle for VGA. But the end result is still very great. The video features both the slides and the camera feed in the same picture. This makes it very easy to follow the presentation.

Soren was so kind to invite me as a guest to the GR8Conf, so I will drop by in Copenhagen on the 23rd of March. Looking forward to see how far the Groovy and Grails have reached. We do see more and more people use Grails and Camel. Likewise the gradle build system seems to be cool as well.

The videos of the presentation is already online and you can find them here.
And the slides is also uploaded to slideshare here.

Thanks to Javagruppen and OpenMinds for hosting such a great event. I had a great time visiting Ã…rhus.

2013-04-29

Apache Camel 2.11 released

Last week Apache Camel 2.11 was released.

Apache Camel 2.11 has been released
This blog post is a summary of the most noticeable new features and improvements.
For a detailed description, see the Camel 2.11 release notes.

1) New components
As usual each new release contains a number of new components, contributed by our large user base. Thanks guys.

For example there is camel-cmis which allows to integrate with content management systems, such as Alfresco, or any of the systems supported by Apache Chemistry, which is what we use in camel-cmis.

We also got a new camel-couchdb for integrating with our fellow Apache CouchDB project.

Also very exiting is the new camel-elasticsearch component, to integrate with the excellent elastichsearch project.
In the hawt new project hawtio we are also working on some great new stuff with elastichsearch around log aggregation and analytics, with a shiny HTML5 graphical user interface using Kibana. If you haven't see hawtio yet, then make sure to check it out.
Then James Strachan created the new camel-rx component, for integrating Camel beautifully, as Eric Maijer said, with the fantastic Netflix port of Reative Extensions (RX) library. And when we got Java8 as well, this is going to rock.

Then I created the new camel-servletlistener component to allow bootstrapping Apache Camel applications in web applications with no other dependencies. Usually people would need to use Spring or other library to do this. To demonstrate this in example, we have a new servlet-tomcat-no-spring example. As well my blog entry - Camel web applications without Spring, earlier this year about this new functionality. For the upcoming Camel 2.12 we will work on an alternative example using the new blueprint-web module that allows Spring XML like configurations but with only two JARs as dependencies (blueprint-noosgi, blueprint-web). This works beautifully, and we already use it hawtio project to easily bootstrap hawtio web application from a blueprint XML file.

Scott Sullivan stepped up and created the new camel-sjms component for a light-weight JMS component which only depends on the JMS API. This component is expected to be further improved and hardened in the upcoming releases. The camel-sjms component is not a 1 to 1 replacement for the existing camel-jms component. They are two independent components. We want the freedom in camel-sjms to implement the functionality we think is best needed, and as well to avoid the many many options that Spring JMS exposes, and hence creeped into camel-jms as well.

We also have a new component for integration with Redis with the camel-spring-redis component.

And last year I created the camel-urlrewrite component, which allows people to do Camel routes for proxying HTTP services with URL rewrites. I have previously blogged about this as well.

We also created a new control bus component, which allows you to send messages to a control-bus endpoint to control routes. This may make it easier for people to start/stop their Camel routes. This component is expected to be improved in the future, so you for example can get performance statistics and other information as well.


2) SQL component can now consume as well
The SQL component has been improved, so you can now consume as well. This allows you to pickup new data from table(s) and route the data in Camel routes. This is best illustrated by the new camel-example-sql that we created. Oh and we also added support for using named parameters in the SQL queries.


3) Groovy DSL
The Groovy DSL in Camel has been totally overhauled, thanks to community contributions. The DSL is now fully up to date and uses the Groovy'sh style that makes it much more Groovy like. We also added a new Camel Maven Archetype to create a new Camel groovy project.


4) CDI improvements
In the earlier phase of development of Camel 2.11 we worked on improving the camel-cdi component.
We are not there yet but its a big step in the right direction. We are also waiting a bit for Apache DeltaSpike project to do new releases so we can finish the last pieces. So expect this to be improved in upcoming releases as well.


5) camel-netty scales better
We also worked on improving the camel-netty component to be faster. Most noticeable the netty producer that now pools channels for reuse.


6) JAXB controlling namespace prefixes
For people stuck in XML land and using JAXB, then we made it easier to control namespace prefixes, so you 100% can control the prefix names in use. This allows to conform the XML to a naming style, or if you must use a specific prefix name; usually if a legacy system expects prefix names to be hardcoded.


7) Guice 3.0
People who are fan of Guice, would be glad to hear we have upgraded camel-guice to use Guice 3.0 as is. The old guicyfruit dependency, which was needed when using Guice 1.x is now gone.


8) Backlog tracer
We introduced a new backlog tracer, which allows tooling to trace Camel messages at runtime, on-demand. There is new camel-backlog-tracer command(s) for Apache Karaf / ServiceMix, which allows you to trace messages on your running Camel applications at runtime. You can even enable a predicate filter, to only trace matched messages etc.


9) OSGi upgrades
Apache Camel 2.11 now requires OSGi 4.3 and Apache Aries 1.0 if you use the camel-blueprint component. This means that you should use Apache Karaf 2.3 or better as the container.


10) Miscellanies
We have improved the startup of Apache Camel a bit, as well the simple language is now faster when invoking OGNL like expressions. And we disabled the type converter utilization statistics as there is a slight performance impact under heavy load. And we managed to let the camel-jms component re-create temporary queues when doing request/reply over JMS with temporary queues, and the connection has been re-connected (eg automatic self-heal). The camel-cxfrs component has a simpler binding, making it easier to use.

And as usual we have a ton of bug fixes, minor improvements and new features. See the release notes for full details.

Apache Camel 2.11 is available for download from the Apache web site, and Maven users can get it from maven central.

The Camel team is now busy working on Apache Camel 2.12, where we have some exiting new work on improved documentations for Camel components.

2013-04-19

Apache Camel web dashboard with hawtio

I have been waiting patiently for James Strachan to write a blog to introduce us to his latest project - hawtio. This project surely has the potential to become as great or even greater than Apache Camel.

In a one liner, hawtio is:

hawtio is a lightweight and modular HTML5 web console for managing your Java stuff.

Today James is busy doing the release of the hawtio 1.1. This is a very hawt release, that has great functionality already, so we should start spread the word about this project. We have also talked about doing small videos, as recoding what you do in a web browser is easy.

Anyway this blog entry today of mine, is not to steal the thunder from James. I would let him do the introduction of hawtio, and his vision for creating this project.

So in hawtio we have a Camel plugin, that allows you to gain insight into your running Camel applications. So the screenshot below is from hawtio running as a plain web application deployed to JBoss AS 7.1.1. You can use any web container of choice, such as Tomcat, Jetty etc. Though I was tasked to give the JBoss AS a little test spin, and thus had the opportunity to take a screenshot. I have also deployed the Apache Camel example camel-example-servlet-tomcat in the container (its also just a WAR application).

Dashboard in hawtio, with a live Camel diagram and table, updating in real time.
hawtio allows you to create custom dashboards, where you can add any part of a view to the dashboard, and position the views as you please. So I created a Camel dashboard, which has a live diagram of the route from the camel-example-servlet-tomcat. As well a table with the running routes and their state and some key metrics. All the data on the dashboard updates in real time, which is very cool.

And the dashboards can be saved to a git repository, and you can share them with your team. And as its just a URL you can easily access the dashboard, by just copying the url from the browser address bar.

Anyway hawtio has a lot more cool stuff already. And we are having fun hacking on it. Its of course a 100% open source project, ASL licensed, and hosted at github. Everybody is welcome to contribute and hack on it.

Stay tuned, more blogs and videos should be coming in the future.

2013-04-12

Slides from Apache Camel presentation in Copenhagen

Yesterday I gave an Apache Camel presentation in Copenhagen, at the Javagruppen event.
As promised I have uploaded the slides to slideshare, which you can find here.

Next stop is a presentation in Gothenburg, Sweden on April 23, and followed by Ã…rhus, Denmark on May 7th. And a stop in Odense, Denmark is currently being planned.


2013-04-02

Upcoming Apache Camel meetings in Copenhagen, and Gothenburg

I previously blogged about upcoming Apache Camel events in Malmo and Copenhagen.
I had a great time at the Malmo JUG. And thanks to the beer sponsor TT (Three Towns) we had a great and cosy event. It was my first time giving a presentation with a beer in my hand.

My first talk with a beer in hand - Photo (c) FooCafe
I now have confirmation for the event in Copenhagen on April 11th is confirmed and will happen.
You can find details about this event, such as location and time, and how to register at JavaGruppens site at this link.

My presentation will be in English, and include some live demos as well, so at the end of the day, when you get back, you should be able to get started with Camel yourselves. Nineconsult has been so kind of hosting this event - thanks guys.

There is also time for Q and A, so power users of Camel is of course also welcome. We are very keen on hearing your feedback. And discuss the project, and what we can do better, and what lies down the roadmap etc.

Also we have time to check out the cool new web console project we are working on as well - hawtio. That is seriously cool stuff.

The JUG in Gothenburg have reach out to me, to discuss a Camel event on April 23rd. We are currently working out the details - I will post details when I know more about this event.

2013-03-25

Upcoming Apache Camel presentations in Malmo and Copenhagen

There is a couple of events coming up here in Malmo and Copenhagen which involves Apache Camel presentations.

Tomorrow I am presenting "Getting started with Apache Camel" at the Malmo JUG. The event opens at 17:00 pm, and my presentation starts at 17:35. Then we have a presentation about JavaScript and Android development, and followed on by talk on continues integration. Sounds like a great evening with a mix of great talks. And after that we go for beers. So its a great opportunity to learn and meet interesting people working in the industry.

The event is free, and there should be a few more seats available. You can register for the event and read more about the presentations here - http://www.javaforum.se/jf/?meeting=99

The event takes place at Foo Cafe which is not so far from the central station in Malmo.


JavaGruppen Denmark is planning an Apache Camel event on April 11th in Copenhagen. The planning is still in early stages and as I understand it's an after hour event where I will give a talk on Apache Camel, and then followed on by 1 or 2 talks from people who are using Apache Camel in their organization, and share their experience - both good and the bad.

I will be back when I have more details about the event in Copenhagen.


2013-03-19

Today 6 years ago Apache Camel was created

On Monday, March 19th 2007, James Strachan did the first commit what became Apache Camel. The commit log entry is here.

James Strachan founded the Apache Camel project with this first commit 6 years ago
Even in the first commit, todays users of the latest Apache Camel releases, can see the structure of the route builder, and the API with the component, endpoint, exchange, producer, consumer et all.

You can take a look in this unit test from the first commit.

Though here is a teaser with the RouteBuilder from the first commit


RouteBuilder builder = new RouteBuilder() {
  public void configure() {
    from("seda://a").to("seda://b");
  }
};

And the content based router was already included. Though today the headerEquals predicate has been slightly changes to header("foo").isEqualTo("bar") instead.


RouteBuilder builder = new RouteBuilder() {
  public void configure() {
    from("seda://a").choice()
      .when(headerEquals("foo", "bar")).to("seda://b")
      .when(headerEquals("foo", "cheese")).to("seda://c")
      .otherwise().to("seda://d");
    }
};

In summer 2007 Apache Camel 1.0 was released, and that was a very impressive first release, which I previously have blogged about.

Today 6 years later, we have done 13677 commits on trunk (37 different committers), accordingly to the Apache Camel git commit log (git log --oneline | wc -l).

... and yeah we are closing in on the anticipated Apache Camel 2.11 release (likely being GA in next month).

2013-02-28

CamelOne 2013 - Call For Paper

CamelOne is happening this year as well, so its the 3rd consecutive conference all about open source integration and messaging, where Apache Camel is the star of the show.

CamelOne 2013 - We are calling for papers
The conference takes place yet again in the United States in Boston MA in june 2013.

If you have topics for talks then we are calling for papers. You can submit your proposals here.
If you are not familiar with CamelOne, then you can get a flavor of the conference, by viewing last years sessions here (registration required) and/or check out some photos from last year as well.


2013-01-12

Camel in Action - 2 years later

Two years ago the Camel in Action book was done and published.

Camel in Action, published January 2011
So when we started the journey of the book we knew we had once shot of getting this right. So Jonathan and I went all in, and worked our socks off to deliver a quality book, that do justice to the fantastic project that Apache Camel is.

So with all the hard work Jonathan and I put into it, what did we get from this? Well it was not really about the money, as that can't cover cost of living. Though to treat myself good I purchased a coffee machine - which I still enjoy using ever day; the coffee tast really good.

The community liked the book and have gotten good reviews. Looking today at the Amazon site, we have 10 top-mark reviews. The last review is as late as December 26th 2012, so people are still finding this book useful.

Ten 5-star customer reviews of the Camel in Action book from Amazon
The book seems to go well over the years, for example the last quarterly sales figures I have (Q2 2012), the book sold 701 units. 

As previous said, Jonathan and I, went all in with this book. So after the book was published, we have keep to our toes, and ensured that we keep the following up to date:
Sidenote: As a reader of other books, this is not always the case, where the authors have this devotion to their book. As a reader I fell disappointed to get started with a book, and the source code is outdated, and don't compile/work anymore. Or that mistakes in the book is not pointed out in an errata. And when I want to interact with the authors, they are not responsive on the official book forum. 
When our readers find a mistake in the book, they report that to us on the book forum, or by sending private emails. We then take a look, and if there is a mistake, make sure to get the errata updated, and submit that to Manning; whom them publish the update on the book site. For example the last errata update is from July 2012.

Over the years since the book was published, we have released new versions of Apache Camel. So as a courtesy to new readers we are keeping the books source code in sync with the Camel releases. We only missed the Camel 2.6.0 release which was the 1st release after the book was published. So today we have 13 updates to the source code available for our readers.

Source code for the Camel in Action book, updated with the following Apache Camel releases.
The source code for the book has also been useful to the Camel team. So every time we are working on a new release, we run that release against the source code of the book, to test for any regressions etc. Over the time we have actually found a number of bugs, which we could fix before cutting the release.

So what's next? Well thats a story for another blog entry, if/when that story starts...


2013-01-04

Camel 2.11 - Camel web applications without Spring

So today we are in the year of 2013.

And as I write this we have just added a new component to the upcoming Apache Camel 2.11, that allow to run web applications with Camel without having to rely on Spring Framework to boostrap Camel. Or any other 3rd party frameworks for that matter.

A bit ashamed to say that in the year 2013 we are a bit late to the party to offer this out of the box in Apache Camel.

In modern web containers supporting Servlet 3.0 spec. you can programmatically bootstrap your code using the new @WebListener annotation. But even so there is still work to be done, as you would need to setup and configure Camel, and as well ensure resources is unregistered and stopped when stopping the web application.

I have not found a neat way of using @WebListener and allowing external configuration of your framework such as Apache Camel. I dont really want to hardcode my configuration, or have to invent my own way of loading external configuration and configure my application. Anyone know of a solution to this problem?

Anyway we also wanted a solution that works for old school Servlet 2.x based container. There is a ton of them out there running. And even so the old school configuration with a web.xml file works just as good in the newer Servlet 3.0 containers. So we wanted an out of the box solution that fit both worlds.

Example to showcase

We have a number of examples at Apache Camel, and one is a simple web application that is ready to be deployed as a .war file in Apache Tomcat, or any other web container.

This example is using the Spring Framework to boostrap a Spring XML file, where we have Camel embedded. So what we did was to redo this example without the need for Spring.

The two examples is documented at the Apache Camel site at:


CamelServletContextListener

In Camel 2.11 we have a new component named camel-servletlistener, which offers a new CamelServletContextListener class which you configure in the web.xml file. This will then boostrap a CamelContext, and use the context init parameters as its configuration.

This context listener has a lot of configuration, so you can easily configure Camel to your needs.
The options is listed in the Camel docs at: http://camel.apache.org/servletlistener-component.html

And in case you need to execute any custom logic when Camel is starting/stopping then we have an API for that, a CamelContextLifecycle interface. There is more details and examples at the Camel docs.

To see this in action, I suggest after reading this blog, check out the new example, as well the documentation for the camel-servletlistener component.

Dissecting the example

Having the two examples

We can take a peak at the difference between the two of them, when deploying to fresh installation of Apache Tomcat 7.0.30 using Java 1.6. 

servlet-tomcat-example
size: 5.8 MB
jars: 19
classes loaded: 4507
current heap size: 10 MB

servlet-tomcat-no-spring-example
size: 2.9 MB
jars: 10
classes loaded: 3698
current heap size: 8 MB

I used jconsole to look at the number of loaded classes in the JVM with the Apache Tomcat and the deployed example. The heap size was measured as the lowest value I could get after performing GC.

So we cut 10 JARs and 3MB from the distribution. As well avoid loading in the shy of 1000 classes.

Remarks

I just want to emphasize that the goal of this new camel-servletlistener component is to allow people to easily bootstrap their Camel applications in any web container, without the need to be tied to any particular 3rd party framework such as Spring. The Apache Camel project aims to be neutral and agnostic; allowing people to run Camel in any way and container of choice.