Subject Re: [IB-Java] Problem with FBManagedConnection
Author David Jencks
Thanks for finding this problem. I will fix it. The
connectionEventListener management works differently when the
ConnectionManager is standalone or hooked into an app server: I didn't
finish adapting this code to standalone, apparently.

david jencks

On 2002.02.16 13:38:05 -0500 patcom123 wrote:
> After much debugging and hair pulling, i think i have found a bug
> with the FBManagedConnection and ManagedConnectionPool classes.
> Unfortunately, i haven't found a solution as i'm still trying to get
> to grips with how all the connection management stuff fits together.
>
> The problem occurs when you use get a connection a number of times
> and then try to get a number of simultaneous connections - which are
> the same object and not distinct as should be?
>
> I've traced the problem to the ConnectionEventListeners. One is
> created everytime a connection is allocated, but it is never removed
> upon releasing a connection. This means that in the notify function
> of FBManagedCOnnection the number of times the loop which checks the
> event listeners and dispatches events increases every time a
> connection is allocated. This results in multiple copies of the same
> connection being added to the connection pool.
>
> This seems to be a bug unless i'm misunderstanding how things work?
> It would seem sensible to remove a connection listener whenever a
> connection is closed/error occurred in the while loop in notify? But
> i'm not sure if this would affect other things or there is a better
> place to stick it?
>
> Any suggestions
>
> JOHN
>
>
>
>
>
>
> To unsubscribe from this group, send an email to:
> IB-Java-unsubscribe@egroups.com
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>
>
>