Jay Sprenkle wrote:
On 7/26/06, John Stanton <[EMAIL PROTECTED]> wrote:
Jay Sprenkle wrote:
>> > Will the mutex replace file locking for database access control?
>> >
>>
>> No. A mutex only works within a single process.
>
>
> I was thinking it might make a good compile time option.
> If you aren't going to access the database from multiple machines then
> the mutex could replace file locking as an access control mechanism.
> My guess was it would be much faster,
> but would only work correctly in that special case.
If the mutex capability were layered then there could be an init call
which would let the user choose a thread-type mutex for multi-threaded
single process, a semaphore-type kernel structure for multiple processes
and some form of lock manager (as I remember using on VMS) for a network.
Almost a "plug-in" serialization organization. I don't think I've ever
seen anyone do it that way, but that might be really valuable.
The embedded software guys would just love it.
We had an ISAM product which worked after that fashion. It replaced a
server-type implementation which in unfamiliar hands was more trouble
than a bag full of monkeys.