summaryrefslogtreecommitdiffstats
path: root/source3/lib/dbwrap/dbwrap_tdb.c
Commit message (Collapse)AuthorAgeFilesLines
* move the dbwrap library to the top levelMichael Adam2012-05-141-447/+0
| | | | | Autobuild-User: Michael Adam <obnox@samba.org> Autobuild-Date: Mon May 14 04:04:55 CEST 2012 on sn-devel-104
* s3:lib:dbwrap: use [u]int[num]_t consistently in dbwrap_tdb.cMichael Adam2012-05-131-1/+1
|
* s3-dbwrap: Add dbwrap_set_stored_callbackVolker Lendecke2012-04-201-0/+1
| | | | This is a per-db function that is called whenever some record is modified
* s3-dbwrap: Add "db_context" to "db_record"Volker Lendecke2012-04-201-0/+2
|
* s3-dbwrap: Add dbwrap_db_idVolker Lendecke2012-04-201-0/+25
| | | | This returns a blob uniquely identifying the database
* s3: Fix Coverity ID 2744: CHECKED_RETURNVolker Lendecke2012-04-191-1/+6
|
* s3-dbwrap: push lp_ctx up another layer in the stackAndrew Bartlett2012-04-181-4/+1
| | | | | | | | | | This will allow db_open_tdb() to be called from common code, which may already have a loadparm context loaded. It also slowly moves the lp_ctx up the stack, as required to remove the library loop between smbconf and the registry. Andrew Bartlett
* s3: Add dbwrap_try_fetch_lockedVolker Lendecke2012-04-171-9/+32
| | | | | | | | | | This is designed to spread the load on individual ctdb records to allow upper layers to do backoff mechanisms. In the ctdb case, do not get the record if a local lock is already taken. If we are not dmaster, do at most one migrate attempt. For the tdb case, this is a nonblocking fetch_locked. If someone else has the lock, give up.
* s3-dbwrap: Move "lock_order" initialization to db_open_xxVolker Lendecke2012-03-161-1/+3
|
* tdb_wrap: Move to specific directory.Jelmer Vernooij2012-03-101-1/+1
| | | | | | | | | | It's a bit confusing to mix low-level and high-level libraries. We had multiple libraries in one directory, and there were have circular dependencies with other libraries outside that directory (in this case, samba-hostconfig). Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sat Mar 10 23:13:01 CET 2012 on sn-devel-104
* s3:dbwrap fix return value of db_tdb_parseChristian Ambach2011-12-161-1/+5
| | | | | use the TDB ecode to determine the NTSTATUS return value and not the return code that is just -1
* s3-dbwrap: Remove the "fetch" db_context callbackVolker Lendecke2011-12-151-65/+0
| | | | Signed-off-by: Michael Adam <obnox@samba.org>
* s3-dbwrap: Make dbwrap_parse_record return NTSTATUSVolker Lendecke2011-12-151-5/+31
| | | | | | | Also, the parser now returns void. The parser is called if and only if dbwrap_parse_record returns NT_STATUS_OK. Signed-off-by: Michael Adam <obnox@samba.org>
* s3-dbwrap: Simplify db_tdb_fetchlock_parse a bitVolker Lendecke2011-12-131-10/+11
| | | | Introduce a local variable for the result, replace "state->result" by "result"
* s3-dbwrap: Use simpler code for logging keysVolker Lendecke2011-12-081-18/+23
|
* s3: Fix some blank line endingsVolker Lendecke2011-12-081-5/+5
|
* s3:dbwrap_tdb: pass NTSTATUS code further up from db_tdb_fetch_parse in ↵Michael Adam2011-11-301-1/+1
| | | | | | | db_tdb_fetch() Autobuild-User: Michael Adam <obnox@samba.org> Autobuild-Date: Wed Nov 30 01:46:31 CET 2011 on sn-devel-104
* s3:dbwrap: turn the fetch dbwrap method to NTSTATUS return code.Michael Adam2011-11-291-10/+25
| | | | | This implement more correct NTSTATUS handling inside the backends. This ensures that data.dptr != NULL if return code is NT_STATUS_OK.
* lib/util: Add back control of mmap and hash size in tdb for top level buildAndrew Bartlett2011-10-131-2/+6
| | | | | | | | This passes down a struct loadparm_context to allow these parameters to be checked. This may be s3 or s4 context, allowing the #if _SAMBA_BUILD_ macro to go away safely. Andrew Bartlett
* s3:dbwrap: move definitions of db_record and db_contect structs to ↵Michael Adam2011-10-111-0/+1
| | | | | | dbwrap_private.h The API and callers now only need the forward declarations.
* s3:dbwrap: add specific dbwrap_wipe() implementation to dbwrap_tdbGregor Beck2011-10-111-0/+8
| | | | Signed-off-by: Michael Adam <obnox@samba.org>
* s3:dbwrap: add specific dbwrap_exists() implementation to dbwrap_tdbGregor Beck2011-10-111-0/+8
| | | | Signed-off-by: Michael Adam <obnox@samba.org>
* s3:dbwrap: move the db_open_tdb() prototype to a new header dbwrap_tdb.hMichael Adam2011-10-111-0/+1
|
* dbwrap_tdb: handle tdb2 return values properly.Rusty Russell2011-09-141-4/+4
| | | | | | | | | TDB2 versions of tdb_parse_record etc return an error code, not -1. Turn those into -1/0 in dbwrap_tdb to insulate the rest of the code from that change. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* s3:dbwrap_tdb: correctly catch the error from the return code of tdb_parse ↵Michael Adam2011-08-251-1/+6
| | | | in db_tdb_fetch()
* s3:dbwrap: move all .c and .h files of dbwrap to lib/dbwrap/Michael Adam2011-07-291-0/+379
Autobuild-User: Michael Adam <obnox@samba.org> Autobuild-Date: Fri Jul 29 13:34:22 CEST 2011 on sn-devel-104