Since we're on a major migration process of this website, some component documents here are out of sync right now. In the meantime you may want to look at the early version of the new website
https://camel.apache.org/staging/
We would very much like to receive any feedback on the new site, please join the discussion on the Camel user mailing list.

Camel proposes different solutions to allow your solution to be scalable, to distribute the load between different instances. The choice will depend on how you will deploy/package Camel (standalone mode, embedded in a J2EE or OSGI server, ...) and how the servers will be configured (master/slave, ...).

Loadbalancing

This approach allows to distribute the load between different endpoints. The from endpoint plays the role of a 'proxy' when we use by example a jetty server

loadbalance()

Clustering

The clustering can be achieved in different ways : Work distribution, Consumer competition, ... depending how you would like to configure your infrastructure (one or several instances running on the same machine or distribute across a cloud of servers).

  • Same JVM & CamelContext

Different Camel components can be used depending if the work must be done in a sync or async way

    • Without persistence

Async : seda:// + threads()

Sync : direct:// + threads()

  • Same JVM but different CamelContext

This approach is suitable for solutions running in standalone mode or deployed in Web Application Server (different WAR/EAR)

vm://

Remark : This component cannot be used between different OSGI servers

    • With persistence

JMS queue engine : jms:// + threads()
Activemq queue engine : activemq:// + threads()

  • Different JVM & CamelContext

When the infrastructure offers the possibility to deploy the application on several machines, then you can use the approaches presented before. That means means that you will deploy the same application on several nodes and in this case, we have competitor consumers. Depending on the load on the servers, messages can be consume by application 1 running on Server 1 instead of application 2 running on Server 2.

If you prefer to deploy routes on servers having different CPU/memory, then you can use the following components

    • Within or between different instances of OSGI servers (SMX4)

nmr://

Camel can be not only plugged on the NMR bus but can also use the clustering functionality offered by ServiceMix 4 ()

Cloudcomputing

  • Cassandra
    It could be interesting to create a Cassandra endpoint to allow to consume
    info/camel messages from Cassandra DB (NOSQL database) or to push there
    camel message (using id + binary stream). It might also make an interesting
    aggregator implementation since its also distributed & can support multi-master
  • Camel-terracotta
    Extends the SEDA component
© 2004-2015 The Apache Software Foundation.
Apache Camel, Camel, Apache, the Apache feather logo, and the Apache Camel project logo are trademarks of The Apache Software Foundation. All other marks mentioned may be trademarks or registered trademarks of their respective owners.
Graphic Design By Hiram