Disk buffering of resultsets

From: Enrico Olivelli - Diennea <enrico(dot)olivelli(at)diennea(dot)com>
To: "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org>
Subject: Disk buffering of resultsets
Date: 2014-09-19 10:44:43
Message-ID: ADD972C51196844491C410BCD4146DCD60A99AA819@dnaexc01.diennea.lan
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Hi,
we are moving from Oracle to PostgreSQL and we hit a serious problem.
When executing a query with a large result set your driver loads each record in memory and this is a blocking problem for us.

The work-around is to use server-side cursors (http://jdbc.postgresql.org/documentation/head/query.html) but in order to do this we have to change autocommit mode of the transaction and this will change transaction semantics of out code.
Many JDBC drivers provide some swap-to-disk function in oredr to deal with huge result sets
Something like "if we are loading in RAM more than X MBs than swap on disk"
or "if we are loading in RAM more than X rows than swap on disk" (more simple to implement)

We can contribute with some patch

Thank you

Enrico Olivelli
Software Development Manager @Diennea
Tel.: (+39) 0546 066100 - Int. 925
Viale G.Marconi 30/14 - 48018 Faenza (RA)

MagNews - E-mail Marketing Solutions
http://www.magnews.it<http://www.magnews.it/>
Diennea - Digital Marketing Solutions
http://www.diennea.com<http://www.diennea.com/>

________________________________
Rimani aggiornato sul mondo dell'email marketing e del digital marketing: visita il nostro blog! http://blog.magnews.it

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Albe Laurenz 2014-09-19 10:55:25 Re: Please implement simple failover scenario
Previous Message Enrico Olivelli - Diennea 2014-09-19 10:38:44 Please implement simple failover scenario