Hi,
The minIdle value during this test was:
<parameter>
<name>minIdle</name>
<value>20</value>
</parameter>
any other suggestions?
Thanks in advance, Henrik
On Fri, 10 Sep 2004 11:21:08 -0400
"Shapira, Yoav" <[EMAIL PROTECTED]> wrote:
>
> Hi,
> The initial connections can be closed if idle, depending on your pool
> configuration, so you might be creating new connections each time even
> with the pool. Check your minIdle setting.
>
> If you're creating a new connection each time, a tiny bit of overhead
> can be expected for a pool over a direct DriverManager call. But that
> defeats the purpose of pooling. If your pool is properly configured and
> has a connection waiting, it should be a little bit more than a hash
> lookup to return the connection, which would be significantly faster
> than creating a new one.
>
> Yoav Shapira
> Millennium Research Informatics
>
>
> >-----Original Message-----
> >From: Henrik Rathje [mailto:[EMAIL PROTECTED]
> >Sent: Friday, September 10, 2004 11:16 AM
> >To: [EMAIL PROTECTED]
> >Subject: DBCP Performance?
> >
> >Hi,
> >has enyone of you recently measured the performance of the DBCP
> >Connection Pool? I compared
> >
> ><snip>
> >long start = System.currentTimeMillis();
> >Class.forName("ca.edbc.jdbc.EdbcDriver");
> >Connection dbcon = DriverManager.getConnection(loginUrl, loginUser,
> >loginPa$
> >long diff = System.currentTimeMillis() - start;
> >System.out.println("creating connection without pool took: " + diff + "
> >mil$
> ></snip>
> >
> >with
> >
> ><snip>
> >long start = System.currentTimeMillis();
> >Connection dbcon = ds.getConnection( );
> >long diff = System.currentTimeMillis() - start;
> >System.out.println("creating connection with pool took: " + diff + "
> >milise$
> ></snip>
> >
> >And got surprisingly results like this:
> >
> >creating connection without pool took: 465 miliseconds
> >creating connection with pool took: 585 miliseconds
> >
> >In my tests the connection pool is always slower, so what did I do
> wrong?
> >I guess this Parameter is responsible for holding active Connections in
> >the Pool:
> ><parameter>
> > <name>initialSize</name>
> > <value>20</value>
> ></parameter>
> >So there shold be active Connections before the getConnection( ) is
> >called .. Any ideas?
> >Regards, Henrik
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
>
> This e-mail, including any attachments, is a confidential business communication,
> and may contain information that is confidential, proprietary and/or privileged.
> This e-mail is intended only for the individual(s) to whom it is addressed, and may
> not be saved, copied, printed, disclosed or used by anyone else. If you are not
> the(an) intended recipient, please immediately delete this e-mail from your computer
> system and notify the sender. Thank you.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]