1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

13 Commits

Author SHA1 Message Date
Andrew Tridgell
0f41961e4f first cut at adding full transactions for ctdb to samba3
(This used to be commit f91a3e0f7b)
2008-08-13 11:54:08 +02:00
Stefan Metzmacher
dfb181ab73 dbwrap: add dbwrap_tdb2 backend
This backend can be used untill ctdb knows about real
transactions.

It stores a master tdb in a shared location and a readonly copy
on the local harddisk. Reads are always on the local tdb
and writes always on both. Change notify messages are send
to all message context, which ask for them. With the notifies
it's possible to just update the changed records, instead of
copying all records (which is the fallback).

You need to configure:

dbwrap:use_tdb2=yes
dbwrap_tdb2:master directory=/some/shared/path
dbwrap_tdb2:local directory=/var/lib/samba

metze
(This used to be commit aa6230de0d)
2008-04-12 09:14:09 +02:00
Volker Lendecke
2aa7dc8bc6 Fix a confusing variable name
(This used to be commit 32c992e957)
2008-03-28 13:44:30 +01:00
Stefan Metzmacher
474916b70c dbwrap: add db_open_trans()
This should be used when transactions are wanted.
For now it's just a wrapper of db_open(), but this
will change.

metze

Signed-off-by: Stefan Metzmacher <metze@samba.org>
(This used to be commit 74a070b8a2)
2008-03-27 18:14:56 +01:00
Michael Adam
32691a7022 build: don't autogenerate prototypes for util_tdb and dbwrap anymore.
Stick to hand-written headers (that are there anyways).
Add some missing prototypes to util_tdb.h and dbwrap.h.

I did not bother to add a header for each single dbwrap backend
open function but put the prototypes for the open functions into
the central dbwrap.h.

Michael
(This used to be commit edf4dbed27)
2008-03-25 15:55:34 +01:00
Volker Lendecke
541b8dec4e Add transactions to the dbwrap API
Only filled in for tdb so far, for rbt it's pointless, and ctdb itself needs to
be extended
(This used to be commit 0a55e018dd)
2008-03-10 21:08:44 +01:00
Alexander Bokovoy
68694369fc Merge CTDB-related fixes from samba-ctdb 3.0 branch (http://samba.org/~tridge/3_0-ctdb)
Signed-off-by: Alexander Bokovoy <ab@samba.org>(This used to be commit 0c8e23afbb)
2008-01-16 12:09:48 +03:00
Volker Lendecke
94a354493a Add dbwrap bystring service routines
(This used to be commit 1e214b536b)
2007-12-10 16:06:32 +01:00
Volker Lendecke
977497071b Cosmetic fix
(This used to be commit 8d8cb8f9cc)
2007-11-22 16:00:13 +01:00
Andrew Tridgell
5e54558c6d r23784: use the GPLv3 boilerplate as recommended by the FSF and the license text
(This used to be commit b0132e94fc)
2007-10-10 12:28:22 -05:00
Jeremy Allison
d824b98f80 r23779: Change from v2 or later to v3 or later.
Jeremy.
(This used to be commit 407e6e695b)
2007-10-10 12:28:20 -05:00
Volker Lendecke
a950301685 r23220: Add traverse_read to dbwrap
(This used to be commit b38dc5ffdf)
2007-10-10 12:22:55 -05:00
Volker Lendecke
4c185a6077 r22775: For the cluster code I've developed a wrapper around tdb to put different
database backends in place dynamically.

The main abstractions are db_context and db_record, it should be mainly
self-describing, see include/dbwrap.h.  You open the db just as you would open
a tdb, this time with db_open(). If you want to fetch a record, just do the
db->fetch() call, if you want to do operations on it, you need to get it with
fetch_locked().

I added dbwrap_file.c (not heavily tested lately) as an example for what can
be done with that abstraction, uses a file per key. So if anybody is willing
to shape that up, we might have a chance on reiserfs again.... :-)

This abstraction works fine for brlock.tdb, locking.tdb, connections.tdb and
sessionid.tdb. It should work fine for the others as well, I just did not yet
get around to convert them.

If nobody loudly screams NO, then I will import the code that uses this soon.

Volker
(This used to be commit e9d7484ca2)
2007-10-10 12:21:56 -05:00