Kurt Zeilenga [Fri, 9 Apr 1999 18:33:52 +0000 (18:33 +0000)]
Streamline code during finds to reduce contention on c_mutex.
Move Debug messages outside of c_mutex. Other LDBM cache codes
also should be streamlined. Resultant approaches should then
be applied to back-bdb2.
Kurt Zeilenga [Thu, 8 Apr 1999 03:57:25 +0000 (03:57 +0000)]
Changes to support FreeBSD LinuxThreads port. Namely don't rely
on errno not getting changed by Debug(). Likely a problem elsewhere.
Tests run okay, excepting concurrency has "no such object" problems.
Kurt Zeilenga [Tue, 6 Apr 1999 23:44:27 +0000 (23:44 +0000)]
New LinuxThreads detection. Correctly detects FreeBSD's LinuxThreads port
(but not sure if it's usable yet). Needs to be tested on various versions
of Linux native LinuxThreads.
Kurt Zeilenga [Tue, 6 Apr 1999 21:57:16 +0000 (21:57 +0000)]
Add ldap_pvt_thread_destory() to un-ldap_pvt_thread_initialize().
Move all SunOS routines (ie: _sleep() and its helpers) to thr_lwp.c
so that it's internals can be 'static'. Add 'static' to thr_lwp.c.
Add comment to LWP: NEEDS WORK, may not compile! Need some
SunOS user to sort out the details. Volunteers?
Kurt Zeilenga [Sun, 4 Apr 1999 20:36:35 +0000 (20:36 +0000)]
Cleanup socket() detection.
Move select() detection forward, error if not available.
Move select() args type check forward so it can be used in subsequent tests.
Kurt Zeilenga [Fri, 2 Apr 1999 19:09:59 +0000 (19:09 +0000)]
cache: implement try_again loop if cache entry is not ready.
id2entry: when an error occurs attempting to insert fetched
entry into cache, check to see if entry was added by another
thread. If so, return the entry added by the other thread.
The concurrency tests now run without the dreaded "no such object"
error messages!
Kurt Zeilenga [Thu, 1 Apr 1999 20:26:09 +0000 (20:26 +0000)]
Updates for NT4 (MSVC5++).
Removed external include/library paths from projects. External paths should
be set via Tools | Options | Directories. This allows each developer the
freedom to install external libraries where they desire.
Used libdb.lib instead of libdbs.lib to avoid thread conflicts.
Added hs_regex.lib to library input. We require some form of regex, this
library works (and is relatively easy for the user to install).
Removed a little lint which MCVC5 detected.
Need to sort out single-threaded vs multithreaded library generation.
Kurt Zeilenga [Tue, 30 Mar 1999 00:07:37 +0000 (00:07 +0000)]
IRIX (very strange) default libraries have working pthread_create() but
no pthread_detach(). So, augment pthread_create() in default libraries
test to detach created thread.
Kurt Zeilenga [Mon, 29 Mar 1999 05:15:59 +0000 (05:15 +0000)]
Rework ac/socket.h for HAVE_WINSOCK:
tcp_close -> closesocket
ioctl -> ioctlsocket
Modify codes to use tcp_close() instead of close() for sockets.
Modify ioctl codes to be compatible with WINSOCK.
Kurt Zeilenga [Mon, 29 Mar 1999 01:40:17 +0000 (01:40 +0000)]
Add wait4/3 detection.
Modify slapd_tester to use pid_t and wait macros. May need to
implement additional macros in ac/wait.h (in addition to
WEXITSTATUS and WIFEXITED).
Kurt Zeilenga [Sun, 28 Mar 1999 22:43:43 +0000 (22:43 +0000)]
All implementations of lutil_lockf (aka ldap_lockf) block until
the lock is acquired. Add comments to that effect. Remove
unnecessary busy loops from slapd/lock.c and slurpd/lock.c.
Kurt Zeilenga [Sun, 28 Mar 1999 21:39:02 +0000 (21:39 +0000)]
Update lutil_lockf (aka: ldap_lockf) to hide implementation in
library, not header. Eliminate need for <ac/unistd.h> to sometimes
include <fcntl.h> and/or <sys/file.h>. Change lock API to expect
fd not FILE*. Allows wider use and eliminates requirement that
lutil_lockf.h depencency on stdio.h.
Implemented lockf, fcntl, and flock locking in lutil/lockf.c.
Additional implementations (including no-op) may be needed.
Update slapd/lock.c and slurpd/lock.c to use new API.