From:
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To:
"Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc:
"Heikki Linnakangas" <heikki(dot)linnakangas(at)enterprisedb(dot)com>,
"Simon Riggs" <simon(at)2ndQuadrant(dot)com>,
"Alvaro Herrera" <alvherre(at)commandprompt(dot)com>,
"decibel" <decibel(at)decibel(dot)org>,
"Itagaki Takahiro" <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>,
"pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org>
Subject:
Re: FSM search modes
Date:
2009-10-01 20:47:59
Message-ID:
3969.1254430079@sss.pgh.pa.us (view raw or flat )
Thread:
2009-09-17 15:26:19 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
2009-09-18 01:47:39 from Itagaki Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>
2009-09-18 06:09:15 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
2009-09-18 06:57:50 from decibel <decibel(at)decibel(dot)org>
2009-09-30 22:13:04 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 15:24:37 from decibel <decibel(at)decibel(dot)org>
2009-10-01 15:56:09 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2009-10-01 16:05:40 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-01 16:28:08 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
2009-10-01 16:31:43 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-01 16:32:08 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 16:42:15 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
2009-10-01 16:45:03 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
2009-10-01 16:55:03 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-01 18:36:34 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 18:55:18 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-01 19:23:15 from Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
2009-10-01 19:43:14 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 20:07:51 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 20:47:59 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-01 21:09:33 from Robert Haas <robertmhaas(at)gmail(dot)com>
2009-10-01 22:07:41 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 22:17:20 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-01 22:49:45 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-02 14:03:01 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-10-03 03:33:49 from Bruce Momjian <bruce(at)momjian(dot)us>
2009-10-01 20:46:26 from Robert Haas <robertmhaas(at)gmail(dot)com>
2009-10-01 21:08:12 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2009-10-01 21:18:54 from Robert Haas <robertmhaas(at)gmail(dot)com>
2009-10-02 19:59:19 from decibel <decibel(at)decibel(dot)org>
2009-10-01 22:02:28 from Dimitri Fontaine <dfontaine(at)hi-media(dot)com>
2009-10-02 06:53:51 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
2009-10-01 21:23:52 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2009-09-18 12:43:20 from Hannu Krosing <hannu(at)2ndQuadrant(dot)com>
2009-09-18 19:44:34 from Simon Riggs <simon(at)2ndQuadrant(dot)com>
Lists:
pgsql-hackers
"Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov> writes:
> The way I figure it, if there is a 0.01 chance to reset the sweep,
> then there's a 0.99 percent chance to continue the sweep from the last
> position. 0.99^229 is about 0.1, which means there is a 10% chance
> not to have reset after that many attempts to advance.
Right, so the odds would be that a backend will confine its insertion
attempts to the first 229 pages containing a usable amount of free
space. As long as the number of backends concurrently inserting
into the relation is well under 229, this seems perfectly fine.
(Hm, so we might want to make the probability depend on
max_connections?)
A possible downside of keeping things compact this way is that you'd
probably get a longer average search distance because of all the early
pages tending to remain full. Maybe what we want is some bias against
inserting in the last half or quarter of the table, or some such rule,
rather than necessarily heading for the start of the relation.
regards, tom lane
In response to
Responses
pgsql-hackers by date
Next :From: Bernd HelmleDate: 2009-10-01 21:07:32
Subject : Re: TODO item: Allow more complex user/database default
GUC settings
Previous :From : Robert HaasDate : 2009-10-01 20:46:26
Subject : Re: FSM search modes