TDB2 inclusion?

Stefan (metze) Metzmacher metze at
Fri Jun 3 06:42:39 MDT 2011

Hi Rusty,

> Now, I'm not committing to TDB2 stability at this stage, but integration
> would make my life simpler (vs. continually rebasing).  The major
> missing piece (other than debugging and tuning) is that I need to
> implement the ability to read and write TDB1 files.
>         git:// #tdb2-wip

It would be really nice if we could get rid of the TDB_ALLOW_NESTING hack
and implement nested transactions correctly.

The API could look like this:

enum TDB_ERROR tdb_transaction_start(struct tdb_context *tdb,
				     uint64_t flags, /* we need a way to do a non-blocking start */
				     struct tdb_context **trans);

When we start a transaction this way, the 'tdb_context' of 'tdb' would
become read-only
until tdb_transaction_commit()/cancel() is called on the returned
'trans' context.

Also the users of the 'tdb' context would see the state before the
This would reduce a lot of risks which can happen when using fake
transaction nesting
within one process together with nested event loops.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <>

More information about the samba-technical mailing list