Unnessecary use of new Integer(n) in AbstractJdbc2ResultSet

Поиск
Список
Период
Сортировка
Искать
От
Daniel Migowski
Тема
Unnessecary use of new Integer(n) in AbstractJdbc2ResultSet
Дата
Msg-id
41ED3F5450C90F4D8381BC4D8DF6BBDC4F095AFD@EXCHANGESERVER.ikoffice.de
Список
Дерево обсуждения
Unnessecary use of new Integer(n) in AbstractJdbc2ResultSet Daniel Migowski <dmigowski@ikoffice.de>
Re: Unnessecary use of new Integer(n) in AbstractJdbc2ResultSet Kris Jurka <books@ejurka.com>
 Hi,

I am using the postgresql driver 8.3-604-jdbc3, and noticed something strange in my profiling reports:

In Line 2518 of AbstractJdbc2ResultSet, in function findColumnIndex, there is a call to "new Integer(n)", which takes 2% overall time in my app! It should be replaced by "Integer.valueOf(n)", because this doesn't create any new instances on Integer for the usecase found here!

Regards,
Daniel Migowski
В списке pgsql-jdbc по дате отправления
От: Bernd Helmle
Дата:
От: Kris Jurka
Дата:
FAQ