From: lisp linux
Subject: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <yoqdnYDDC5n9zpLVnZ2dnUVZ_oaonZ2d@comcast.com>
Hi
I posted this to the mailing list postmodern-devel ..AT.. common-lisp.net
but it got rejected by the list service
Here is the original

I think the function next-statement-id in

http://common-lisp.net/project/postmodern/darcs/postmodern/postmodern/prepare.lisp
would not work correctly in a multi threaded situation.

I am not sure about the ensure-prepared, i guess it may be ok since i
expect to use a connection in only one thread at a time.

I ran across this, cause I was looking at the source to understand the
usage of prepared statement stuff.

-Antony
P.S.: I can't really provide any code, cause at present I am unable to
devote sufficient time to my CL hobby projects

From: lisp linux
Subject: Re: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <GJadne1ofYiIkIXVnZ2dnUVZ_tLinZ2d@comcast.com>
lisp linux wrote:
> Hi
> I posted this to the mailing list postmodern-devel ..AT.. common-lisp.net
> but it got rejected by the list service
> Here is the original
> 
> I think the function next-statement-id in
> 
> http://common-lisp.net/project/postmodern/darcs/postmodern/postmodern/prepare.lisp 
> 
> would not work correctly in a multi threaded situation.
> 
> I am not sure about the ensure-prepared, i guess it may be ok since i
> expect to use a connection in only one thread at a time.
> 
> I ran across this, cause I was looking at the source to understand the
> usage of prepared statement stuff.
> 
> -Antony
> P.S.: I can't really provide any code, cause at present I am unable to
> devote sufficient time to my CL hobby projects
No responses at all ? :(
-Antony
From: Pascal J. Bourguignon
Subject: Re: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <7c1w4n3ggp.fsf@pbourguignon.anevia.com>
lisp linux <·········@lisp.linux> writes:

> lisp linux wrote:
>> Hi
>> I posted this to the mailing list postmodern-devel ..AT.. common-lisp.net
>> but it got rejected by the list service
>> Here is the original
>> I think the function next-statement-id in
>> http://common-lisp.net/project/postmodern/darcs/postmodern/postmodern/prepare.lisp
>> would not work correctly in a multi threaded situation.
>> I am not sure about the ensure-prepared, i guess it may be ok since
>> i
>> expect to use a connection in only one thread at a time.
>> I ran across this, cause I was looking at the source to understand
>> the
>> usage of prepared statement stuff.
>> -Antony
>> P.S.: I can't really provide any code, cause at present I am unable to
>> devote sufficient time to my CL hobby projects
> No responses at all ? :(
> -Antony

You don't have enough time for your CL hobby, so you'd like us to have
your hobby fun for you?

-- 
__Pascal Bourguignon__
From: lisp linux
Subject: Re: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <Hqudnf1AlL57zYTVnZ2dnUVZ_uWdnZ2d@comcast.com>
Pascal J. Bourguignon wrote:
> lisp linux <·········@lisp.linux> writes:
>>> I think the function next-statement-id in
>>> http://common-lisp.net/project/postmodern/darcs/postmodern/postmodern/prepare.lisp
>>> would not work correctly in a multi threaded situation.
>>> I am not sure about the ensure-prepared, i guess it may be ok since
>>> i
>>> expect to use a connection in only one thread at a time.
>>> I ran across this, cause I was looking at the source to understand
>>> the
>>> usage of prepared statement stuff.
>>> -Antony
>>> P.S.: I can't really provide any code, cause at present I am unable to
>>> devote sufficient time to my CL hobby projects
>> No responses at all ? :(
> You don't have enough time for your CL hobby, so you'd like us to have
> your hobby fun for you?
> 
OK, Thank you. I was worried that my posts aren't even being read.

I did read the manual and tried to read and understand the code. So it's not like I spent no time.

I wrote what I did cause I thought it might be helpful in improving the lib even though I may not be 
contributing code directly.

Essentially I am doing what I can.

-Antony
From: Leslie P. Polzer
Subject: Re: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <2541eb76-8f08-46a7-b2cc-55eea29d54a9@27g2000hsf.googlegroups.com>
On Apr 23, 5:18 pm, lisp linux <·········@lisp.linux> wrote:

> I think the function next-statement-id in
>
> http://common-lisp.net/project/postmodern/darcs/postmodern/postmodern...
> would not work correctly in a multi threaded situation.

It would appear so.


Take a look at Elephant's Postmodern backend which works fine (at
least in the development head) and uses Postmodern in a multi-threaded
environment extensively.

  Leslie
From: lisp linux
Subject: Re: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <oYWdna_Qwsb_UbjVnZ2dnUVZ_jWdnZ2d@comcast.com>
Leslie P. Polzer wrote:
> On Apr 23, 5:18 pm, lisp linux <·········@lisp.linux> wrote:
> 
>> I think the function next-statement-id in
>>
>> http://common-lisp.net/project/postmodern/darcs/postmodern/postmodern...
>> would not work correctly in a multi threaded situation.
> 
> It would appear so.
> 
> 
> Take a look at Elephant's Postmodern backend which works fine (at
> least in the development head) and uses Postmodern in a multi-threaded
> environment extensively.
> 
>   Leslie
My comment was about the 'prepared statement' support code being not thread safe in Postmodern.
I am guessing Elephant does not use prepared statements. Does it ?

-Antony
From: Leslie P. Polzer
Subject: Re: postmodern thread safety in prepared statements functionality
Date: 
Message-ID: <8c71ea1c-e6c9-40f1-9a95-f9770f95e35a@e39g2000hsf.googlegroups.com>
> My comment was about the 'prepared statement' support code being not thread safe in Postmodern.
> I am guessing Elephant does not use prepared statements. Does it ?

It does so, extensively :)

grep -i prepare elephant/src/db-postmodern

  Leslie