Hi,

Thanks a lot for the patch! It looks good, and I will apply it for the
next release. I hope I can also write a test case. Using
java.util.concurrent is an option, but I don't think it's required
(actually I want to avoid using it for Java 1.4 compatibility). I know
the algorithm is not "fair" but in reality I don't think thats a
problem (fair scheduling is very slow).

Regards,
Thomas

On Sunday, August 8, 2010, Joe <[email protected]> wrote:
> Dario,
>
> The mechanism you describe in your patch is exactly what I was
> thinking would do the trick.  Specifically it addresses the issue of
> properly waiting the configured time interval regardless of how many
> cycles it takes.
>
> This approach still has the risk that a waiter could be starved out of
> getting the connection resource while other waiters within that time
> could obtain the resource.  This is because the mechanism for waiting/
> notification is unordered and not guaranteed.  Practically though, i
> don't think this is a real issue and the cost to fix it might exceed
> the benefit (at least without using Java 6 concurrency libraries).
>
> Thanks!
> Joe
>
> On Aug 7, 1:08 pm, Dario Fassi <[email protected]> wrote:
>>  Sorry, but my previous post spoiling the attachment.
>>
>> El 07/08/10 13:37, dariof escribió:
>>
>> > Attached goes a candidate patch that almost solve the premature exit
>> > of getConnection() method.
>> > Use it as sees fit.
>>
>> > regards,
>> > Dario.
>>
>>
>>
>>  JdbcConnectionPool.patch
>> 1KViewDownload
>
> --
> You received this message because you are subscribed to the Google Groups "H2 
> Database" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/h2-database?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to