You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by Christian Schneider <ch...@die-schneider.net> on 2007/12/09 13:16:04 UTC

Running several input adapters where only one is active at a time

Hello,

I am searching for a pattern that occurs quite often in EAI but I have 
not found it in the list of documented patterns.

I want to process input from an external source and feed it into a 
queue. To make the scenario fault tolerant at least two adapters have to 
be installed on two separate machines. They read input from a custom 
source (in my case I have to connect to a legacy system via an API and 
subscribe to a feed). The catch is the at any time only one of the 
adapters may be active.

One way to achieve this is sending heartbeats on a topic and having a 
rule which adapter should be active. At the moment I start all adapters 
inactive and give them a weight setting. Now if an adapter receives no 
heartbeats or only heartbeats from adapters with lower weights it will 
activate.

While I probably can implement this on my own I am wondering if someone 
has already solved the problem.
Does servicemix provide any support for this? Or do you know any good 
implementation?

Best regards

Christian

-- 

Christian Schneider
---
http://www.liquid-reality.de