On 6/13/07, bluedog <[EMAIL PROTECTED]> wrote:

I am  interested in different methods for linking two ServiceMix buses.  The
use case is the customer department has its own set of service interfaces
and at some point, needs to pass along messages to the finance department.
Each department has its own bus.

I've read through the news items and these are the ways I have found so far
to connect two different SM containers:

1. JMS:  Have customer application put a message onto their local bus and
have the outbound binding component place this message onto a JMS queue for
transmission to the finance department.

2. RemoteClient: Have the customer application receive its message from SM
and use RemoteClient to attach to the finance SM.  To avoid hard coding the
address, the RemoteClient URL could be placed in a properties file or JNDI
tree somewhere.

As a side note, does it matter if the customer application runs as an
external service receiving messages from a provider BC or as a Service
Engine?  Theoretically there is some sort of performance hit for getting on
and off the bus, but in someways it seems by pushing such specific,
non-crosscutting application logic into a service engine might be against
the paradigm.

Are there additional considerations if you try and use RemoteClient from
within a service engine? Most of the examples I've seen using the
RemoteClient class appear to be external web-applications or standalone java
test classes.

I recommend networking multiple instances of ServiceMix using ActiveMQ
via its network of brokers concept
(http://activemq.apache.org/networks-of-brokers.html). This is how I
always recommend networking distributed instances of ServiceMix
because it provides a logical normalized message router (NMR) between
all distributed instances of ServiceMix. This means that the NMR has
knowledge of all components installed in all instances of ServiceMix,
no matter whether they're local or remote. Then you're just deferring
message routing to the NMR - this is its purpose.

As far as publishing messages to BCs in ServiceMix, you can do this
using the remote client, but I would recommend considering the use of
either HTTP or JMS. I prefer JMS because of the messaging guarantees
it provides. With JMS, you're simply publishing a XML message to a
queue that is then received by a servicemix-jms SU and passed along to
whatever service is next in the flow.

The reason I'm making these recommendations is to stick with message
routing completely through ServiceMix instead of picking and choosing
how things work. I've found that it's much easier for my customers to
remain consistent than it is to create custom use cases for everything
- unless (and this is a big cavaet) there's a very good reason for not
doing so.

Bruce
--
perl -e 'print unpack("u30","D0G)[EMAIL 
PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

Apache Geronimo - http://geronimo.apache.org/
Apache ActiveMQ - http://activemq.org/
Apache ServiceMix - http://servicemix.org/
Castor - http://castor.org/

Reply via email to