[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[xmlblaster] Re: cluster configuration
Hi Marcel,
Thanks for your advice !
But I still can't get it to work. Here are several things I've noticed :
- if I start server A using parameter '-call[core] true', clients can't
subscribe using this server : I get a NullPointerException.
- if I start server A without this parameter, the subscription works fine.
But when a publisher publishes on port 7600, only the server connected to
port 7600 gets the message. Same thing if a publisher publishes on port
7601 : only the client connected to 7601 gets the message.
A little question about the property file of server A : don't we need to
tell server A how to find server B ?
Thank you for your help,
--
Brome
Marcel Ruff
<ruff at swand.lake. To: xmlblaster at server.xmlBlaster.org, Bertrand-Raphael.Maquel at ses-astra.com
de> cc:
Subject: Re: [xmlblaster] cluster configuration
08/10/2002 08:44
PM
Bertrand-Raphael.Maquel at ses-astra.com wrote:
>Hi,
>
>I'm currently trying to use 2 XMLBlaster clusters to make clients
>communicate between 2 different geographical places. Actually, I'm just
>testing a prototype of this configuration on a single PC, but you get the
>idea.
>
>Like this :
>
>
> Cluster A ====================(non reliable
>connection)================== Cluster B
> / \
>/ \
> / \
>/ \
> client 1 client 2
>client 3 client 4
>
>So, basically, what I need is to have all messages transmitted to all
>clients whatever the domain is, so that each client at any place can
>receive any message.
>
>What would be the best configuration for the servers ? Should I try
>something with acceptDefault ? Or declare both clusters as masters for all
>kinds of domain ?
>
>So far, the only thing I managed to do was send from client 1 to all
>clients of cluster B, or from client 1 to all clients of cluster A. But I
>can't get the message sent to all the clients at once.
>
>Do anyone see a simple configuration pattern I could use for this ?
>
Mirroring is not explicitly implemented yet (as nobody needed it up to now)
but you can simulate it like this:
Save the two attached files to your harddisk, they configure
two xmlBlaster nodes.
1. Start the servers:
-----------------------
java -jar ~/xmlBlaster/lib/xmlBlaster.jar -propertyFile A.properties
-call[core] true
java -jar ~/xmlBlaster/lib/xmlBlaster.jar -propertyFile B.properties
The first node 'A' is configured as master and listens on port 7600
The other node 'B' is slave for everything and listens on port 7601
2. Start two subscribers, one for A and one for B:
--------------------------------------------------------
java org.xmlBlaster.client.reader.SubscribeMessage -xpath
"/xmlBlaster/key[starts-with( at oid,'HelloFrom')]" -port 7600
java org.xmlBlaster.client.reader.SubscribeMessage -xpath
"/xmlBlaster/key[starts-with( at oid,'HelloFrom')]" -port 7601
You can see that they connect to the different xmlBlaster nodes
subscribing the same
messages.
3. Start two publishers, one for A and one for B:
------------------------------------------------------
java org.xmlBlaster.client.feeder.PublishFile -xmlKey "<key
oid='HelloFromA'/>" -port 7600
java org.xmlBlaster.client.feeder.PublishFile -xmlKey "<key
oid='HelloFromB'/>" -port 7601
Here it is: both publisher publish a message and these are received
by both subscribers.
Note:
------
I have added support for domain="*" configuration so you don't need
to play around with domains in your messages.
You need to checkout the newest from cvs that the above works!
(or if you don't want to you need to use explicit domains or filtering
with XPATH
for cluster setup).
regards,
Marcel
>
>Thanks,
>--
>Brome
>
>
>
>--
>DISCLAIMER:
>This e-mail contains proprietary information some or all of which may be
>legally privileged. It is for the intended recipient only. If an
addressing
>or transmission error has misdirected this e-mail, please notify the
author
>by replying to this e-mail. If you are not the intended recipient you must
>not use, disclose, distribute, copy, print, or rely on this e-mail.
>
>
>
>
>
#------------------------------------------------------------------------------
# Configures an xmlBlaster node with the name "A"
#
# Change the hostname='' setting if A is running on another IP,
# for example to hostname='192.168.1.2'
#
# INVOKE: java org.xmlBlaster.Main -propertyFile A.properties
#------------------------------------------------------------------------------
# Switch on CORBA driver only, listens on port 7600:
Protocol.Drivers=IOR:org.xmlBlaster.protocol.corba.CorbaDriver
Protocol.CallbackDrivers=IOR:org.xmlBlaster.protocol.corba.CallbackCorbaDriver
jacorb.verbosity=0
ns=false
port=7600
# Configuer cluster - the A node:
cluster=true
cluster.node.id=A
#------------------------------------------------------------------------------
# Configures an xmlBlaster node with the name "B"
#
# Change the hostname='' setting if A is running on another IP,
# for example to hostname='192.168.1.2'
#
# INVOKE: java org.xmlBlaster.Main -propertyFile B.properties
#------------------------------------------------------------------------------
# Switch on CORBA driver only, listens on port 7601:
Protocol.Drivers=IOR:org.xmlBlaster.protocol.corba.CorbaDriver
Protocol.CallbackDrivers=IOR:org.xmlBlaster.protocol.corba.CallbackCorbaDriver
jacorb.verbosity=0
ns=false
port=7601
# Switch off telnet access, we don't need it
admin.remoteconsole.port=-1
# Example to switch on SOCKET driver only:
#Protocol.Drivers=SOCKET:org.xmlBlaster.protocol.socket.SocketDriver
#Protocol.CallbackDrivers=SOCKET:org.xmlBlaster.protocol.socket.CallbackSocketDriver
#socket.port 7501
# Configuer cluster - the B node:
cluster=true
cluster.node.id=B
cluster.node.master[B]=\
<clusternode id='B'>\
<master type='DomainToMaster' acceptDefault='false'/>\
</clusternode>
# Configure cluster - how to find A:
cluster.node[A]=\
<clusternode id='A'>\
<info>\
<address type='IOR' hostname='' port='7600'/>\
</info>\
<master type='DomainToMaster'>\
<key queryType='DOMAIN' domain='*'/>\
</master>\
</clusternode>
--
DISCLAIMER:
This e-mail contains proprietary information some or all of which may be
legally privileged. It is for the intended recipient only. If an addressing
or transmission error has misdirected this e-mail, please notify the author
by replying to this e-mail. If you are not the intended recipient you must
not use, disclose, distribute, copy, print, or rely on this e-mail.