source3/registry/reg_objects.c assumes dbrwap will be in use ...

Michael Adam obnox at samba.org
Sun Jan 11 15:16:03 MST 2015


Hi Richard,

this use of dbwrap_store_bystring does not use the registry.tdb.

This uses an in-memory rbt as an index.
It is just conveniently wrapped into the dbwrap api
by the dbwrap_rbt backend.
We do this in a couple of places for internal indexes/hashes.

So I think this should be safe for you to use.
Or have I misunderstood you?

Cheers - Michael


On 2015-01-11 at 13:14 -0800, Richard Sharpe wrote:
> Hi folks,
> 
> Now that I have gotten some aspects of Zookeeper under control, I
> would like to reuse the code in source3/registry/reg_objects.c,
> however, it has one big deficiency. In regsubkey_ctr_hash_keyname it
> does:
> 
>         werr = ntstatus_to_werror(dbwrap_store_bystring_upper(ctr->subkeys_hash,
>                                                 keyname,
>                                                 make_tdb_data((uint8_t *)&idx,
>                                                               sizeof(idx)),
>                                                 TDB_REPLACE));
> 
> I think I will need to change that and have different backends for the
> actual storing of keys when Zookeeper or others (like etcd) are in
> use.
> 
> Can anyone suggest a work-around here?
> 
> -- 
> Regards,
> Richard Sharpe
> (何以解憂?唯有杜康。--曹操)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20150111/b510ed19/attachment.pgp>


More information about the samba-technical mailing list