[postmodern-devel] is postmodern thread safe

Samantha Atkins sjatkins at mac.com
Tue Oct 2 04:19:48 UTC 2007


On Sep 26, 2007, at 2:44 AM, Marijn Haverbeke wrote:

> Hold it! The competition is advertising on *my* list now? Hah, never
> mind, CL-RDBMS is a nice system, but to answer your question about
> Postmodern: Yes, it is thread-safe, as long as you do not have two
> threads use the same connection object at the same time. Using
> WITH-CONNECTION, it is easy to give each thread its own connection.
> The only part of the library that uses global mutable state is the
> connection pool, and I used bordeaux-threads' mutexes to prevent
> problems there.
>

Is WITH-CONNECTION getting threads out of a pool?  It seemed to  
optionally to do that but my early reading also made me wonder if  
those were active connections or still had some overhead before they  
could be used.  My own project idea was to take my ample (20+ years)  
of object persistence experience and produce a oodbms equivalent layer  
that can sit on any relational or many other underlying stores.  The  
ideas is that this layer can be used by any language front end to as  
transparently as possible persist objects, structures and  
relationships between them with consistent transaction support,  
concurrency, caching and throughput mostly independent of front end  
language efficiency.

Obviously this layer needs to be seriously multi-threaded.  I  
sometimes have doubts about doing this project in Lisp because things  
like threading support are not consistent and dependable on all  
platforms using non-proprietary Lisp.    Lisp is attractive to me for  
the mileage I can get in the way of generated specialized code and on  
the fly refactoring and other reactive programming tricks.  It also  
can come in very handy for offering a very full object query language  
that produces much more optimal code than less capable languages can  
support.   But the meat of such a layer could certainly easily be done  
in C# (I most of that "meat" in Java a while back) with much more  
portability and some serious other advantages like being able to be  
used fully in a single process for any .net/mono capable language.

- samantha




More information about the postmodern-devel mailing list