From: Kris Jurka <jurka@ejurka.com>
To: Sebastien DIAZ <sebastien.diaz@gmail.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: JDBC Driver for Postgres. I add a little cache for al less lot
Date: Wed, 05 Jul 2006 19:01:34 -0700
Message-ID: <44AC6EFE.8090300@ejurka.com> (raw)
In-Reply-To: <2a2b6a3d0607020220k556c56fbx724642503de2ab3@mail.gmail.com>
References: <2a2b6a3d0607020220k556c56fbx724642503de2ab3@mail.gmail.com>
Sebastien DIAZ wrote:
> I use an utilities who use the method isnullable of field too more.
>
> And this methods (and others) call directly Postgres to obtain the
> information.
>
> When I see the log request of postgre I see 1000 request for this and
> 100 request for my apllication
>
>
> This utilities are hibernate and jahia . see the web sites to see that
> is it!
>
> But to enhnance I change the code of the postgre driver. But you
> imagine I use less time to enhance, and the code is certainly not the
> best result of a good reflexion. but it resolve my problem.
> I add a simple cache manager to save the final result (not a resulset)
> of queries and its parameters.
>
Please do not send mail directly to maintainers, but instead please send
it to the pgsql-jdbc@postgresql.org mailing list. Also do not send your
entire source tree. Use diff to produce a patch modifying just the
files you've changed as I've attached.
Finally you cannot cache results from different connections. They can
be to different servers, different databases, different usernames.
There is no reason to believe that they should produce the same results.
The utility of a cache on a per connection basis is much more limited
and it seems this is probably something that can be better done at a
higher level than the JDBC driver although unfortunately you don't have
control of that code.
Kris Jurka
Attachments:
cache.patch.gz (application/gzip, 5.5K) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: jurka@ejurka.com, sebastien.diaz@gmail.com
Subject: Re: JDBC Driver for Postgres. I add a little cache for al less lot
In-Reply-To: <44AC6EFE.8090300@ejurka.com>
References: <2a2b6a3d0607020220k556c56fbx724642503de2ab3@mail.gmail.com> <44AC6EFE.8090300@ejurka.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox