Propagating state change to multiple peers

Adam Gandelman adamg at
Wed Jul 13 21:03:52 UTC 2011

On 07/13/2011 01:17 PM, Gustavo Niemeyer wrote:
> I'm not entirely sure I see the need you have, so please correct me if
> I'm on the wrong track.
> I believe you're looking for a concept we conveniently named as "peer
> relations".  If you declare a relation of type "peer" (rather than
> requires/provides), all of the service units deployed will
> automatically join a relation which is made with the ring itself, so
> "relation-list" will get you the precise number of peers participating
> in the relation, and you get relation-get on any of them.
> Does that solve the issue you're finding?

I believe that may solve my issue.  If I follow, I can 'relation-list' 
to find out how many service units in the relation.  On addition of a 
new peer, I can update configuration and for each unit in 
'relation-list', use 'relation-set' to export my new config and in turn 
cause relation-changed to be fired on each peer?

I was not aware peer relations differed from regular require/provide 
relations.  Is this documented somewhere?


More information about the Ensemble mailing list