[Openais] Ideas for a cleaner/easier to use objdb API

Fabio M. Di Nitto fabbione at fabbione.net
Tue Jul 28 20:34:46 PDT 2009


On Wed, 2009-07-29 at 09:03 +1200, Angus Salkeld wrote:
> Why do you need this?
> 
> I know the config file is set out like this, but why force the requirement
> onto objdb?
> 
> -Angus
> 
> On Wed, Jul 29, 2009 at 8:07 AM, Fabio M. Di Nitto<fabbione at fabbione.net> wrote:
> > On Wed, 2009-07-29 at 07:30 +1200, Angus Salkeld wrote:
> >> Hi
> >>
> >> Here is a first attempt at an easier to use API for objdb.
> >
> >> 2) Each object/key must have a unique name (as a string)
> >> 2.1) So no child objects named the same (service, logging,...)
> >
> > This breaks current requirements from the objdb as we need to have
> > objects in the same level with the same string name.

Because you are looking only at corosync config file type.

Try to load an xml file (like cluster.conf) into the objdb:

<clusternodes>
 <clusternode name="diapolon" nodeid="1" votes="1"/>
 <clusternode name="cerberus" nodeid="2" votes="1"/>
</clusternodes>

how do you map the 2 clusternode entries if you can't have more than one
object with the same name (clusternode) at the same level?
name/nodeid/votes are keys+values.

Fabio



More information about the Openais mailing list