From: | Paul Thomas <paul(at)tmsl(dot)demon(dot)co(dot)uk> |
---|---|
To: | Oliver Jowett <oliver(at)opencloud(dot)com> |
Cc: | "pgsql-jdbc (at) postgresql (dot) org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: PreparedStatement parameters and mutable objects |
Date: | 2004-01-12 13:26:01 |
Message-ID: | 20040112132601.A17510@bacon |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
On 12/01/2004 00:39 Oliver Jowett wrote:
> Paul Thomas wrote:
>> Having followed this very interesting thread, I'm still wondering
>> exactly how much measurable improvement could be achieved. I read an
>> article on IBM developerWorks (sorry can't remember the URL) which
>> stated that, on modern VMs, things like object creation aren't the
>> performance bogeys that they once were. So I'm thinking that before we
>> make a decision about committing to a change which might break someones
>> app, is there any way by which we could measure the effects of the
>> proposed change?
>
> The problem is that it's very specific to the application workload; what
> case do we measure?
I think you would need something which closely models you app's work load.
> The reason I'm interested in doing this for is not the direct CPU
> overhead of object creation (none of the JDBC code is on our main
> execution path), but the effect that object creation has on GC interval
> and pause. We're running a low-latency app where an extra 50ms pause due
> to GC has a large impact on our latency figures .. so the less garbage
> we generate in the first place, the better. We could farm the JDBC work
> out to a separate VM, but that gets complex quite fast.
Reducing the amount of garbage created is never a bad thing. Do you have
an estimate of the % reduction you think you could achieve?
>
> Aside from the change in behaviour, the change I'm proposing has no real
> downside I can see -- it's not a CPU-vs-memory tradeoff, we're just
> generating fewer intermediate copies altogether. More of a code
> complexity-vs-runtime cost tradeoff I suppose.
Sounds fine to me.
--
Paul Thomas
+------------------------------+---------------------------------------------+
| Thomas Micro Systems Limited | Software Solutions for the Smaller
Business |
| Computer Consultants |
http://www.thomas-micro-systems-ltd.co.uk |
+------------------------------+---------------------------------------------+
From | Date | Subject | |
---|---|---|---|
Next Message | bvol | 2004-01-12 13:33:19 | unsubscribe |
Previous Message | Dave Cramer | 2004-01-12 12:54:15 | Re: PreparedStatement parameters and mutable objects |