On Sat, Oct 19, 2002 at 08:02:37PM -0700, Barry Lind wrote:
>
> Teofilis,
>
> I have applied this patch. I also made the change that so that when
> connected to a 7.3 database this optimization will always be used. This
> is done by having the server do the character set encoding/decoding and
> always using UTF-8 when dealing with the jdbc client.
>
> thanks,
> --Barry
>
Hi,
Ok, thanks for applying that. Well, after doing some benchmarks, I can
say that java sucks. Don't get me wrong- it is still my language of
choice and it is better than many other alternatives, but I have yet to
see a JVM that has good performance, and no strange bottlenecks. I was
quite annoyed to see that executing a query via JDBC and iterating over
it from java took 6x the time it takes to execute it with psql. This
patch helps a bit, but the performance overhead is still huge. Well, I
looked over PostgreSQL JDBC driver code serveral times, and now I don't
see anything more that can be optimized. The things that take up most
time now is transferring everything over network
(PG_Stream.receiveTuple if i remember correctly) and allocating memmory
for byte[] arrays. But I don't know any way to speed them up.
Teofilis Martisius,
teo@mediaworks.lt