camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ricardo Melo <rica...@cflex.com.br>
Subject Dynamic Activemq failover
Date Wed, 03 Mar 2010 21:16:11 GMT
Hi,

I have an issue about using the activemq failover. I think you can help me.

My system uses camel (using cxf, mail, tcp and other components) and uses an
activemq queue to send out messages, using a variable number of routes "TO"
destinations. Recently, We've found the need to use activemq failover when
sending a message, and give a message to user if the communication has a
problem.

In my system all camel routes can be dynamically added/updated, using system
received XML messages that specifies the route name, transport type, address
and an unique id. For each added route, an activemq queue is created with
the sufix "_<routeId>" in its name. Then a camel route is created to send
messages from that queue to the route address specified in the message. Thus
messages can be sent by email, web services, or whatever.

Example:
Message contains message "Hello", route id=1, transport=file, address=:/dir
Would create a route from("activemq:queue:out_1".to("file:/dir")
Then messages to route id=1 would be put in the above queue and then in the
file:/dir

The questions are:

1) How can I declare the failover in this situation?

1) How can I add the failover to the dynamically added queue, using the
received route 'TO' address contained in the message? Is it possible to
configure dynamically, using a RoutBuilder?

I need to declare a failover that tries to send the message to the "TO"
address contained in the message, trying for 1 second.

2) Is it possible to dynamically declare the failover, and if the route is
updated, update the failover configuration?

Thank you,
Ricardo Melo

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message