summaryrefslogtreecommitdiff
path: root/source4/lib
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r10421: following on discussions with simo, I have worked out a way ofAndrew Tridgell10-32/+130
allowing searches to proceed while another process is in a transaction, then only upgrading the transaction lock to a write lock on commit. The solution is: - split tdb_traverse() into two calls, called tdb_traverse() and tdb_traverse_read(). The _read() version only gets read locks, and will fail any write operations made in the callback from the traverse. - the normal tdb_traverse() call allows for read or write operations in the callback, but gets the transaction lock, preventing transastions from starting inside the traverse In addition we enforce the following rule that you may not start a transaction within a traverse callback, although you can start a traverse within a transaction With these rules in place I believe all the deadlock possibilities are removed, and we can now allow for searches to happen in parallel with transactions (This used to be commit 7dd31288a701d772e45b1960ac4ce4cc1be782ed)
2007-10-10r10420: Two minor scons fixesJelmer Vernooij1-1/+1
(This used to be commit 749b19d34f6105c696a07cc2cd39d5acecfc735b)
2007-10-10r10419: Remove unused prototypes of locking functions (thanks Jelmer)Simo Sorce1-10/+1
omment about transactions (This used to be commit 33352507593875a147276841fdb70de8edd668f5)
2007-10-10r10415: The ldb and tdb libraries are bad examples to test out the make protoTim Potter2-11/+5
code as they are marked as NOPROTO in the config.mk files. (This used to be commit 5f530eacbae073e9df6adde316404f70ecfe9122)
2007-10-10r10410: blindly update the scons file for tdb. I'm not sure how this works,Andrew Tridgell1-1/+1
but it definately needs transaction.c now (This used to be commit fa353a5bc562fa1ace0daf6586c42d1d5698c6e4)
2007-10-10r10409: allow smb.conf override of ldb synchronous transactions with ↵Andrew Tridgell1-0/+5
"ldb:nosync = yes/no" (This used to be commit 435cbcf78b70a82c2ec89fab21e4ff8af538f2f1)
2007-10-10r10408: now that we are using tdb transactions we don't need any additionalAndrew Tridgell3-166/+36
locking code in the ldb_tdb backend, except for a single read lock during searches to ensure searches don't cross transaction boundaries The tdb transactions code would map these extra locks to noops anyway (as locking makes no sense inside a transaction), but the work in setting up the locking keys still costs something, and it makes the code needlessly complex (This used to be commit 1b8d368a6771360fb0626127c02b3eb95f3eae59)
2007-10-10r10406: added --nosync option to all ldb tools, so that you can control ifAndrew Tridgell6-16/+29
transactions are synchronous or not on the command line. add LDB_FLG_NOSYNC flag to ldb_connect() so we can make our temporary ldb databases non-synchronous (This used to be commit dba41164e0c52f1e4351bd9057b16661cee3a822)
2007-10-10r10405: added transactions into tdb, and hook them into ldb. See myAndrew Tridgell20-116/+1348
samba-technical posting for more details on the transactions design. This also adds a number of command line arguments to tdbtorture, making it more flexible, and fixes some lock deadlock conditions in the tdbtorture code. (This used to be commit 06bd8abba942ec9f1e23f5c5d546cbb71ca3a701)
2007-10-10r10403: fixed the basedn for testing, and add a debug showing the size of ↵Andrew Tridgell1-1/+4
the test in ldbtest (This used to be commit 740b9f7537d60c7dbd48fe592587b12b304c52d1)
2007-10-10r10402: Make the RPC-SAMLOGON test pass against Win2k3 SP0 again.Andrew Bartlett3-18/+23
I still have issues with Win2k3 SP1, and Samba4 doesn't pass it's own test for the moment, but I'm working on these issues :-) This required a change to the credentials API, so that the special case for NTLM logins using a principal was indeed handled as a special, not general case. Also don't set the realm from a ccache, as then it overrides --option=realm=. Andrew Bartlett (This used to be commit 194e8f07c0cb4685797c5a7a074577c62dfdebe3)
2007-10-10r10385: removed obsolete commentAndrew Tridgell1-1/+0
(This used to be commit 40a8ad2d1eb26d1635b8f188036b04319ffd41b4)
2007-10-10r10384: add _GNU_SOURCE in tdb configureAndrew Tridgell1-0/+1
(This used to be commit 21e5c328a033a4b452b3fd696069ad8bbfa6b9cc)
2007-10-10r10379: Add files for ldb and tdb to proto_files. The tool for building proto.hTim Potter2-16/+26
is busted though. (This used to be commit 54882f88cad1427b6adcb4c956a63e534e7d13e4)
2007-10-10r10377: Save configuration stuff to sconf.cache so it isn't annoyingly runTim Potter4-18/+25
at every single build. Run 'scons configure=1' or delete sconf.cache to force checks to be re-run. Jelmer, I think this stuff is cached in the .sconf_cache directory but the message is still displayed and it looks like it caches the compiled test object file not the actual result of the test. (This used to be commit 9d001dc083937bbf5642af90bc8a8b1a27825de0)
2007-10-10r10374: Add HAVE_* defines (on command-line or in config.h file) for scons +Jelmer Vernooij3-8/+27
some other minor updates (This used to be commit f142c15de1afb2f13a5e23ceb40ce70f0115c8bf)
2007-10-10r10366: More scons fixes. Building et, asn1, lex and yacc files sort-of ↵Jelmer Vernooij6-5/+18
works now (This used to be commit 22f18a84242e5e68a2d57b6d7ff77c089ee7434a)
2007-10-10r10364: Turn gensec:gssapi on by default, except for a login of the formAndrew Bartlett2-14/+7
-Udomain\\user. This will probably break in a few configurations, so please let me know. I'll also work to have a way to inhibit kerberos/ntlmssp, as this removes -k. Andrew Bartlett (This used to be commit 3c0dc570b86e79aea5446d7c3bb9750a11bf8ca4)
2007-10-10r10356: Make the proto generator work with sconsJelmer Vernooij1-3/+3
(This used to be commit a2268f1dd441059955bee30cf2a9028656c14099)
2007-10-10r10348: Add scons scripts for remaining subsystems. Most subsystems build now,Jelmer Vernooij16-31/+24
but final linking still fails (as does generating files asn1, et, idl and proto files) (This used to be commit 4f0d7f75b99c7f4388d8acb0838577d86baf68b5)
2007-10-10r10336: Add sconscript for a couple more subsystems.Jelmer Vernooij9-15/+53
(This used to be commit 59d4450453c25f5cce9b67b808ff0c4433c1d194)
2007-10-10r10335: Build tdb tools into bin directory.Tim Potter1-4/+5
(This used to be commit f35c4763d5c681a74af1f59e75a2f93e99d645cb)
2007-10-10r10332: Fix the build - messaging uses UNIX_PRIVSJelmer Vernooij1-1/+2
(This used to be commit df4a923c64a7fffea3aa01f646b3fba7a83a1b49)
2007-10-10r10330: Add SConscript to more subsystems. Some of the tdb tools build now.Jelmer Vernooij7-10/+68
Start on custom Samba scons tools (for handling proto generation, pidl, etc) (This used to be commit 4bffe4435944fffa3f9680b5a2fe63f2bdd98003)
2007-10-10r10328: Add more emacs python-mode markers.Tim Potter6-0/+12
(This used to be commit 540a3649e88690e829c17d79ecdccdc9ed464845)
2007-10-10r10323: Add first bits required for getting compile with scons working. This ↵Jelmer Vernooij6-0/+43
does not work yet and can exist parallel with the existing build system. (This used to be commit 829568d75985e875e3363d76fb44270a0298c7f8)
2007-10-10r10316: More dynconfig fixesJelmer Vernooij2-2/+0
(This used to be commit 0963ab9c148772b961f17ec779213b0eb861e1dd)
2007-10-10r10315: Remove use of fstring and pstring in dynconfig.cJelmer Vernooij1-12/+0
Remove unused includes of dynconfig.h (This used to be commit 59083b7ba60d518ddb59646c4fd69938afd079b3)
2007-10-10r10312: fix compiler warningStefan Metzmacher1-1/+1
metze (This used to be commit 3309a0f4d90f01e1f6182b797e2bfe3f8380e59c)
2007-10-10r10305: start implementing better error handlingSimo Sorce16-354/+310
changed the prioivate modules API error string are now not spread over all modules but are kept in a single place. This allows a better control of memory and error reporting. (This used to be commit 3fc676ac1d6f59d08bedbbd9377986154cf84ce4)
2007-10-10r10304: check for basic ldb_message sanity and return appropriateSimo Sorce4-14/+59
LDB_ERR_ value (This used to be commit 610f5646f0816820ac9342e81d46d139e26cc918)
2007-10-10r10303: check no attribute is given emptySimo Sorce1-0/+5
(This used to be commit f0ad9495e45ee0d41ef8ca182984599c8e11cabb)
2007-10-10r10302: Introduce ldap like error codesSimo Sorce1-0/+91
(This used to be commit cbe438be6d9b1b7182ab3e63607a2e5b2d5456fb)
2007-10-10r10301: fix standalone compiple after tdb changesSimo Sorce1-1/+4
(This used to be commit acfb4b928363b00346cd8991347d992c76c981d6)
2007-10-10r10299: remove the public (un)lock functions and introduce a transaction basedSimo Sorce13-275/+232
private ldb API ldb_sqlite3 is already working with this model and ldb_tdb will do as soon as tridge finishes the tdb transaction code. currently the transactions are always implicit and wrap any single ldb API call except searching, the transaction functions are currently not made public on purpose. Simo. (This used to be commit 1da4ac2cdcb7e54076f85242a93784260dced918)
2007-10-10r10294: Generate Makefile directly rather then thru Makefile.in. AutoconfJelmer Vernooij1-1/+1
substitution variables are now no longer used. This is one more step towards a (hopefully) perl-based configure (This used to be commit 6f9956a1dd870c0669c288b0fe72b7b1c8773dd0)
2007-10-10r10277: do not ovverride LIKE, thanks to derrel I found out how to doSimo Sorce1-26/+24
the same thing with a harmless user function (This used to be commit 158693b4064bd731aa4f6cdb2fde51d7aa596cf5)
2007-10-10r10258: Fix an unused/duplicate local variable.Tim Potter1-2/+0
(This used to be commit 360be7028c2244391cdd9ed6d156cec8dab9e9e9)
2007-10-10r10253: a fairly large tdb cleanup and re-organise. Nearly all of this changeAndrew Tridgell26-2580/+2234
just involves splitting up the core tdb.c code into separate files on logical boundaries, but there are some minor functional changes as well: - move the 'struct tdb_context' into tdb_private.h, hiding it from users. This was done to allow the structure to change without breaking code that uses tdb. - added accessor functions tdb_fd(), tdb_name(), and tdb_log_fn() to access the elements of struct tdb_context that were used by external code but are no longer visible - simplied tdb_append() to use tdb_fetch()/tdb_store(), which is just as good due to the way tdb locks work - changed some of the types (such as tdb_off to tdb_off_t) to make syntax highlighting work better - removed the old optional spinlock code. It was a bad idea. - fixed a bug in tdb_reopen_all() that caused tdbtorture to sometimes fail or report nasty looking errors. This is the only real bug fixed in this commit. Jeremy/Jerry, you might like to pickup this change for Samba3, as that could definately affect smbd in Samba3. The aim of all of these changes is to make the tdb transactions/journaling code I am working on easier to write. I started to write it on top of the existing tdb.c code and it got very messy. Splitting up the code makes it much easier to follow. There are more cleanups we could do in tdb, such as using uint32_t instead of u32 (suggested by metze). I'll leave those for another day. (This used to be commit 4673cdd0d261614e707b72a7a348bb0e7dbb2482)
2007-10-10r10251: some more work on ldb_sqlite3Simo Sorce5-247/+282
I must say that writing a new module is a very good way to find lot of subtle bugs laying in the code We need more tests! commit oLschema2ldif.c to keep it safe from data losses (rm -fr :-) update test generic to reflect the fix made on comparsion functions (This used to be commit 4357a2db5eadb15519ed93b957b2bad25ebf2a7d)
2007-10-10r10250: the comparison is caseless so we must caseless subtractSimo Sorce1-1/+1
otherwise we get the wrong result when comparing upper case chars with lower case chars (This used to be commit f6ea6e9382f954be819ec82e28598cdf9cf88661)
2007-10-10r10246: Remove unused functionJelmer Vernooij3-218/+1
Move auth-specific file to auth/ (This used to be commit 8aa9711a306b30da905f53148ebe352462852d74)
2007-10-10r10245: Get rid of XFILE in a few places.Jelmer Vernooij3-20/+40
Add fdprintf() and vfdprintf() helper functions. (This used to be commit 6685009f6af94b088084d69a43bcea5f8335ae57)
2007-10-10r10236: fix (C) noteSimo Sorce1-0/+1
(This used to be commit 466e6812c35af9096fea05520c6b59a19793c4d1)
2007-10-10r10233: add commented PRAGMA to avoid fsyncsSimo Sorce1-2/+8
(This used to be commit e5d8d834600040793c1e45c7aaceb374df2b3839)
2007-10-10r10232: Some work on ldb_sqlite3.Simo Sorce2-2026/+1377
It is still far from being usable in samba4 but I want to commit so that the work does not get lost by mistake. This is also a good way to get comments if somebody is interested. Sorry Derrell I ended up rewriting large parts of the code but I find this style much more readable. Thanks for the hard work done. Your work was a good reference for me. ah the current code also shows some good numbers sqlite3 generic test: uid search took 0.05 seconds real 0m12.492s user 0m0.492s sys 0m0.345s with tdb we still get better numbers: uid search took 0.46 seconds real 0m0.892s user 0m0.360s sys 0m0.468s but most of the time is spent in adding operations and I think there's still a lot of space for improvement. Simo. (This used to be commit ace9990060c10d0931f418934b2121aea9512ff7)
2007-10-10r10231: seem I flipped these, fix.Simo Sorce1-2/+2
(This used to be commit 8ddf4de162f42ed53ab0603dd0e1536796f9197e)
2007-10-10r10207: Add some constJelmer Vernooij8-77/+75
(This used to be commit b1ad340b4720e922ae1e332c2a74986b1656358b)
2007-10-10r10200: added a composite_trigger_done() call that allows a composite functionAndrew Tridgell1-5/+0
to cause an event to happen immediately. This allows metzes patch for recognising IPs in resolve_name() to work, and also allows us to remove some of the other code where we currently do specific checks for is_ipaddress(). (This used to be commit 9cc000d868e1257ef6429f6f6f1f9d3c28ca330f)
2007-10-10r10161: Check for alloca.h to prevent incorrect local declaration.James Peach1-1/+1
(This used to be commit efc70d267285a94bcadd690ae4392d278cdeea94)