13 messages in com.mysql.lists.javaRe: performance question
FromSent OnAttachments
Jeff Mathis22 Aug 2003 10:06 
Mark Matthews22 Aug 2003 13:19 
Jeff Mathis22 Aug 2003 13:23 
Mufaddal Khumri24 Sep 2003 22:42 
Mufaddal Khumri25 Sep 2003 00:00 
Mufaddal Khumri25 Sep 2003 01:53 
John Beveridge25 Sep 2003 15:16 
Jeff Mathis30 Sep 2003 12:27 
Mufaddal Khumri08 Oct 2003 21:25 
Mufaddal Khumri08 Oct 2003 21:36 
Dirk Hillbrecht09 Oct 2003 09:57 
Dirk Hillbrecht09 Oct 2003 10:16 
Fouche du Preez14 Oct 2003 02:25 
Subject:Re: performance question
From:Jeff Mathis (jmat@predict.com)
Date:08/22/2003 01:23:17 PM
List:com.mysql.lists.java

Doing that as we speak. I'll get back to you.

I would not say we're having issues. the code is stable enough to start taking a serious look at performance. this is the first bottleneck on the list ...

jeff

Mark Matthews wrote:

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1

Jeff Mathis wrote:

hello all,

I'm using Connector/J 3.0.8 (just upgraded), and mysql-max 4.04 on solaris 2.8. all tables are InnoDB.

We have noticed for some time that loading data from a ResultSet seems to take a fairly vicious downturn when the number of columns in a table is increased. In our application, rows are loaded from a ResultSet via a call to ResultSet.getXXX(int index), where index is the column index. As the number of columns increases, there are more calls to this method, so I would expect some difference in loading data, but I'm surprised at the difference we do see. A 120 column table takes maybe 10 times longer or more to load a row than a 25 column table. (All queries use a multi-column unique index, so I don't think its a matter of not having enough indexes, and all tables have about the same number of rows)

Question is, is this the expected behavior, or is there something else we could do to speed things up?

Can you tell where the time is 'eaten up'...I.e, is it between executing the query and calling ResultSet.next(), or does it take longer to access a column each and every time? You could intrument your code to give out the time it takes to call Statement.executeXXX() (which really ends up loading all of the rows), and how long it takes each ResultSet.getXXX(int), so that we have a clearer picture of what is taking more time than with the smaller result sets.

-Mark

- -- Mr. Mark Matthews MySQL AB, Software Development Manager, J2EE and Windows Platforms Office: +1 708 557 2388 www.mysql.com

Are you MySQL Certified? http://www.mysql.com/certification/ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQE/RnrwtvXNTca6JD8RAi5UAKC07DWsPGaH0/YkzGXI5KvyOpacdACgn/M0 x27Xf+9beuGiMfGKufnuWbU= =RQX3 -----END PGP SIGNATURE-----