Re: All Taxi Services need Index Clustered Heap Append

From: Ants Aasma <ants(dot)aasma(at)eesti(dot)ee>
To: David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>
Cc: Darafei Komяpa Praliaskouski <me(at)komzpa(dot)net>, PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: All Taxi Services need Index Clustered Heap Append
Date: 2018-03-04 10:05:35
Message-ID: CA+CSw_sW2ZFD-ipLhjqJbqaZVrqwqBe0DBDMAL6ZMNUaCU-fEA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Mar 3, 2018 at 4:53 PM, David Rowley
<david(dot)rowley(at)2ndquadrant(dot)com> wrote:
> On 3 March 2018 at 05:30, Darafei "Komяpa" Praliaskouski <me(at)komzpa(dot)net> wrote:
>> Our options were:
>>
>> - partitioning. Not entirely trivial when your id is uuid. To get visible
>> gains, we need to make sure each driver gets their own partition. That would
>> leave us with 50 000(+) tables, and rumors say that in that's what is done
>> in some bigger taxi service, and relcache then eats up all the RAM and
>> system OOMs.
>
> It's a good job someone invented HASH partitioning then.
>
> It would be interesting to hear how your benchmarks go using current
> master + the faster partition pruning patchset [1]. Currently, HASH
> partitioning does exist in master, just there's no partition pruning
> for the non-matching partitions, which is why you need [1].
>
> I think trying with something like 500-1000 partitions might be a good
> place to start.

I don't think that will actually help much. 1000 partitions means each
partition gets data from ~50 vehicles. A 60 tuples per page each page
in the partitioned able will contain on average 1.2 interesting
tuples. So you still have almost one page read per row.

Regards,
Ants Aasma
--
+43-670-6056265
Cybertec Schönig & Schönig GmbH
Gröhrmühlgasse 26, A-2700 Wiener Neustadt
Web: https://www.cybertec-postgresql.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabien COELHO 2018-03-04 10:28:09 Re: 2018-03 Commitfest Summary (Andres #1)
Previous Message Thomas Munro 2018-03-04 10:03:49 Re: select_parallel test failure: gather sometimes losing tuples (maybe during rescans)?