[Spread-users] Newbie question on how to use spread for point to point communication

Vineet Jain (gmail) vinjvinj at gmail.com
Wed Oct 17 07:59:08 EDT 2007


I've installed spread 4.0 package and the updated python  module and
everything seems to be working fine. I have a grid of about 20 compute nodes
each running about 4 different services. Each service runs an event loop and
I was thinking of using spread as the messaging layer between the services
on the different hosts. 

 

I saw an example
(http://www.onlamp.com/pub/a/onlamp/2006/11/30/lamp-and-spread.html?page=2)
on how to use spread for point to point communication:

 

On machine1:

Python 2.4.3 (#2, Apr 27 2006, 14:43:58) 

>>> import spread

>>> c = spread.connect('4804', 'testname1', 0, 0)

>>> print c.receive().message

 

On machine2:

Python 2.4.3 (#2, Apr 27 2006, 14:43:58) 
>>> import spread
>>> c = spread.connect('4804', 'testname2', 0, 0)
>>> c.multicast(spread.RELIABLE_MESS, '#testname1#machine1', 'this is a
point-to-point message')

 

Why do we have to specify <#machine1> when sending a message from machine2.
Isn't testname1 unique identifier for message 1? 

 

or is testname1 the group and what we are saying is that send the message to
group testname1 on machine1. Is this the preffered way to do point to point
communication? 

 

Thanks,

 

Vineet

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.spread.org/pipermail/spread-users/attachments/20071017/820468b0/attachment.html 


More information about the Spread-users mailing list