Re: PATCH: pgbench - random sampling of transaction written into log

From: Tomas Vondra <tv(at)fuzzy(dot)cz>
To: Tomas Vondra <tv(at)fuzzy(dot)cz>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PATCH: pgbench - random sampling of transaction written into log
Date: 2012-09-02 22:40:12
Message-ID: e7ec54867a2cfecb2876d71621aa80d9@fuzzy.cz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Dne 31.08.2012 00:01, Tomas Vondra napsal:
> On 30 Srpen 2012, 23:44, Robert Haas wrote:
>> On Thu, Aug 30, 2012 at 3:48 PM, Tomas Vondra <tv(at)fuzzy(dot)cz> wrote:
>>> That sounds like a pretty trivial patch. I've been thinking about
>>> yet
>>> another option - histograms (regular or with exponential bins).
>>
>> I thought about that, too, but I think high-outliers is a lot more
>> useful. At least for the kinds of things I worry about.
>
> OK, let's fix the current patches first. We can add more options
> later.

So, here is a fixed version of the patch. I've made these changes:

1) The option is now '--sampling-rate' instead of '-R' and accepts
float arguments. I've decided not to use 0.01 = 1% but use 1 = 1%, so it
accepts values between 0 and 100. I find this more natural.

2) I've removed one of the two new variables, the remaining one is used
both to check whether the sampling is enabled and keep the value.

3) I've decided not to enable "-l" whenever the "--sampling-rate" is
used. Again, I find this a bit less magic behavior.

4) I've fixed some formatting issues - if you notice another one that I
don't see, let me know.

Tomas

Attachment Content-Type Size
pgbench-sampling-v3.diff text/plain 4.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tomas Vondra 2012-09-02 22:46:00 Re: PATCH: pgbench - aggregation of info written into log
Previous Message Jeff Janes 2012-09-02 21:53:45 Fwd: [PERFORM] Loose Index Scans by Planner?