Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-04 Thread Alexander Korotkov
paque' set but not used [-Wunused-but-set-variable] BTPageOpaque metaopaque; ^~ Attached patch fixes this. -- Alexander Korotkov Postgres Professional: http://www.postgrespro.com The Russian Postgres Company bt-vacuum-cleanup-fix-warnings.patch Description: Binary data

Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-05 Thread Alexander Korotkov
On Thu, Apr 5, 2018 at 1:32 AM, Alexander Korotkov < a.korot...@postgrespro.ru> wrote: > On Wed, Apr 4, 2018 at 7:29 PM, Teodor Sigaev wrote: > >> Skip full index scan during cleanup of B-tree indexes when possible >> > > Thank you for committing this. > >

Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-05 Thread Alexander Korotkov
would complain about pre-existing indexes. > > In short, this sounds like a place that did not get the memo about > how to cope with un-upgraded indexes. > That's an issue, because meta-page should be upgraded "on the fly". That was tested, but perhaps without assertions. I'll investigate more on this an propose a fix. -- Alexander Korotkov Postgres Professional: http://www.postgrespro.com The Russian Postgres Company

Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-05 Thread Alexander Korotkov
On Thu, Apr 5, 2018 at 2:26 PM, Alexander Korotkov < a.korot...@postgrespro.ru> wrote: > On Thu, Apr 5, 2018 at 6:28 AM, Tom Lane wrote: > >> Peter Geoghegan writes: >> >>> TRAP: FailedAssertion("!(metad->btm_version == 3)", File: >> >&

Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-05 Thread Alexander Korotkov
On Thu, Apr 5, 2018 at 3:24 PM, Alexander Korotkov < a.korot...@postgrespro.ru> wrote: > On Thu, Apr 5, 2018 at 2:26 PM, Alexander Korotkov < > a.korot...@postgrespro.ru> wrote: > >> On Thu, Apr 5, 2018 at 6:28 AM, Tom Lane wrote: >> >>> Peter Geoghe

Re: pgsql: Indexes with INCLUDE columns and their support in B-tree

2018-04-08 Thread Alexander Korotkov
m.postgresql.org/cgi-bin/show_log.pl?nm= > lousyjack&dt=2018-04-07%2020%3A03%3A02 I think attached patch should fix one of those problems. We should match clauses to only key columns of index. I will further investigate the problem with CheckIndexCompatible(). -- Alexander Korot

Re: pgsql: Indexes with INCLUDE columns and their support in B-tree

2018-04-08 Thread Alexander Korotkov
s variables weren't used before, but now they're used to determine whether index column is key. Also, this patch makes ComputeIndexAttrs() initialize classOidP elements with InvalidOid for non-key attributes. -- Alexander Korotkov Postgres Professional: http://www.postgrespro.com

Re: pgsql: Indexes with INCLUDE columns and their support in B-tree

2018-04-08 Thread Alexander Korotkov
On Mon, Apr 9, 2018 at 12:27 AM, Tom Lane wrote: > Alexander Korotkov writes: > > There is also patch for valgrind error in CheckIndexCompatible(). > > It appears that this function didn't initialize ii_NumIndexAttrs and > > ii_NumIndexKeyAttrs before calling

Re: pgsql: Fix behavior of ~> (cube, int) operator

2018-04-10 Thread Alexander Korotkov
_RETURN_FLOAT8(result); > > Seems to be due to sloppy division of changes between f50c80dbb (which > was not back-patched) and 563a053bd. Please fix. > Thank you for catching this. You diagnosis is right. I propose to commit the attached patch to 10 and 9.6. -- Alexander Ko

Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-18 Thread Alexander Korotkov
ng anything other types with explicit typedef'd > widths in WAL records.) Good catch, thank you! I also agree that both these fields should be of float8 type. Please, find attached bt-vacuum-cleanup-float8-num-heap-tuples.patch fixing that. -- Alexander Korotkov Postgres Professional: http

Re: pgsql: Skip full index scan during cleanup of B-tree indexes when possi

2018-04-19 Thread Alexander Korotkov
ersions wasn't relesead), to prevent possible false positive > bug reports I suggest to bump catversion. Objections? I agree, catversion should be bumped for this patch. -- Alexander Korotkov Postgres Professional: http://www.postgrespro.com The Russian Postgres Company

pgsql: Documentation improvement for pg_trgm

2018-06-13 Thread Alexander Korotkov
documentation needs to be backpatched. Author: Bruce Momjian, Alexander Korotkov Discussion: https://postgr.es/m/20180526165648.GB12510%40momjian.us Backpatch: 9.6, where word_similarity() was introduced Branch -- master Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Documentation improvement for pg_trgm

2018-06-13 Thread Alexander Korotkov
documentation needs to be backpatched. Author: Bruce Momjian, Alexander Korotkov Discussion: https://postgr.es/m/20180526165648.GB12510%40momjian.us Backpatch: 9.6, where word_similarity() was introduced Branch -- REL_10_STABLE Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Documentation improvement for pg_trgm

2018-06-13 Thread Alexander Korotkov
documentation needs to be backpatched. Author: Bruce Momjian, Alexander Korotkov Discussion: https://postgr.es/m/20180526165648.GB12510%40momjian.us Backpatch: 9.6, where word_similarity() was introduced Branch -- REL9_6_STABLE Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Fix memory leak in PLySequence_ToJsonbValue()

2018-06-15 Thread Alexander Korotkov
Fix memory leak in PLySequence_ToJsonbValue() PyObject returned from PySequence_GetItem() is not released. Similar code in PLyMapping_ToJsonbValue() is correct, because according to Python documentation PyList_GetItem() and PyTuple_GetItem() return a borrowed reference while PySequence_GetItem()

Re: pgsql: Fix memory leak in PLySequence_ToJsonbValue()

2018-06-15 Thread Alexander Korotkov
On Fri, Jun 15, 2018 at 3:07 PM Alexander Korotkov wrote: > PyObject returned from PySequence_GetItem() is not released. Similar code in > PLyMapping_ToJsonbValue() is correct, because according to Python > documentation I'm sorry for misformatting commit message. I'll be

Re: pgsql: Fix memory leak in PLySequence_ToJsonbValue()

2018-06-15 Thread Alexander Korotkov
On Fri, Jun 15, 2018 at 4:46 PM Tom Lane wrote: > > Alexander Korotkov writes: > > I'm sorry for misformatting commit message. I'll be more careful > > about that in future. > > Maybe I just lack caffeine, but I don't see anything especially > wron

Re: pgsql: Fix memory leak in PLySequence_ToJsonbValue()

2018-06-15 Thread Alexander Korotkov
On Fri, Jun 15, 2018 at 5:25 PM Tom Lane wrote: > Alexander Korotkov writes: > > On Fri, Jun 15, 2018 at 4:46 PM Tom Lane wrote: > >> Maybe I just lack caffeine, but I don't see anything especially > >> wrong with what you wrote? > > > It doesn'

pgsql: Fix typos in release notes

2018-06-19 Thread Alexander Korotkov
Fix typos in release notes Author: Daniel Gustafsson Discussion: https://postgr.es/m/8E8CF1F8-BCB2-4D86-A059-4BF5138F6D87%40yesql.se Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/fb6accd27b99f5f91a7e9e5bd32b98a53fc6d6b8 Modified Files -- doc/src/sgml/

pgsql: Improve wording of release notes item

2018-06-21 Thread Alexander Korotkov
Improve wording of release notes item PostgreSQL 11 introduces compress method for SP-GiST opclasses. That was mistakenly interpreted as compression support for SP-GiST while actually that allows lossy representation of leaf keys. Author: Alexander Korotkov, based on proposal by Darafei

pgsql: Fixes for vacuum_cleanup_index_scale_factor GUC option

2018-06-22 Thread Alexander Korotkov
Fixes for vacuum_cleanup_index_scale_factor GUC option vacuum_cleanup_index_scale_factor was located in autovacuum group of GUCs. However, it affects not only autovacuum, but also manually run VACUUM. It appears that "client connection defaults" group of GUCs is more appropriate for vacuum_clean

pgsql: Increase upper limit for vacuum_cleanup_index_scale_factor

2018-06-26 Thread Alexander Korotkov
vacuum_cleanup_index_scale_factor. So, set upper limit for these GUC and reloption to DBL_MAX. Author: Alexander Korotkov Reviewed-by: Masahiko Sawada Discussion: https://postgr.es/m/CAC8Q8tJCb%3DgxhzcV7T6ctx7PY-Ux1oA-AsTJc6cAVNsQiYcCzA%40mail.gmail.com Branch -- master Details --- https

Re: pgsql: Increase upper limit for vacuum_cleanup_index_scale_factor

2018-06-26 Thread Alexander Korotkov
On Tue, Jun 26, 2018 at 3:35 PM Alexander Korotkov wrote: > vacuum_cleanup_index_scale_factor is used barely to protect against > stalled index statistics. And after detailed consideration it appears > that risk of stalled index statistics is low. And it would be nice to > allow ad

Re: pgsql: Increase upper limit for vacuum_cleanup_index_scale_factor

2018-06-26 Thread Alexander Korotkov
On Tue, Jun 26, 2018 at 3:59 PM Alexander Korotkov wrote: > > On Tue, Jun 26, 2018 at 3:35 PM Alexander Korotkov > wrote: > > vacuum_cleanup_index_scale_factor is used barely to protect against > > stalled index statistics. And after detailed consideration it appears >

Re: pgsql: Increase upper limit for vacuum_cleanup_index_scale_factor

2018-06-26 Thread Alexander Korotkov
On Tue, Jun 26, 2018 at 7:00 PM Tom Lane wrote: > > Alexander Korotkov writes: > > BTW, this line looks cumbersome. > > > +DETAIL: Valid values are b

pgsql: Fix upper limit for vacuum_cleanup_index_scale_factor

2018-06-26 Thread Alexander Korotkov
tests. This commit changes upper limit from DBL_MAX to just "large enough" limit, which was arbitrary selected as 1e10. Author: Alexander Korotkov Reported-by: Tom Lane, Darafei Praliaskouski Discussion: https://postgr.es/m/CAPpHfdvewmr4PcpRjrkstoNn1n2_6dL-iHRB21CCfZ0efZdBTg%40mail

pgsql: Fix wrong file path in header comment

2018-07-11 Thread Alexander Korotkov
Fix wrong file path in header comment Header comment of shm_mq.c was mistakenly specifying path to shm_mq.h. It was introduced in ec9037df. So, theoretically it could be backpatched to 9.4, but it doesn't seem to worth it. Branch -- master Details --- https://git.postgresql.org/pg/commi

Re: pgsql: Fix wrong file path in header comment

2018-07-11 Thread Alexander Korotkov
On Wed, Jul 11, 2018 at 1:26 PM Alexander Korotkov wrote: > Header comment of shm_mq.c was mistakenly specifying path to shm_mq.h. > It was introduced in ec9037df. So, theoretically it could be > backpatched to 9.4, but it doesn't seem to worth it. I didn't backpatch, b

Re: pgsql: Fix wrong file path in header comment

2018-07-11 Thread Alexander Korotkov
On Wed, Jul 11, 2018 at 5:36 PM Tom Lane wrote: > > Alexander Korotkov writes: > > I didn't backpatch, because I thought it doesn't worth it to create > > buzz over single wrong path in the comment. But, I found 12 similar > > cases in our source tree. Do y

pgsql: Fix more wrong paths in header comments

2018-07-11 Thread Alexander Korotkov
Fix more wrong paths in header comments It appears that there are more files, whose header comment paths are wrong. So, fix those paths. No backpatching per proposal of Tom Lane. Discussion: https://postgr.es/m/CAPpHfdsJyYbOj59MOQL%2B4XxdcomLSLfLqBtAvwR%2BpsCqj3ELdQ%40mail.gmail.com Branch --

pgsql: Fix handling of empty uncompressed posting list pages in GIN

2018-07-19 Thread Alexander Korotkov
: Sivasubramanian Ramasubramanian, Alexander Korotkov Backpatch-through: 9.4 Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/309765fa1e317597bfd341fa99dfa97ea5722890 Modified Files -- src/backend/access/gin/gindatapage.c | 20 src

pgsql: Fix handling of empty uncompressed posting list pages in GIN

2018-07-19 Thread Alexander Korotkov
: Sivasubramanian Ramasubramanian, Alexander Korotkov Backpatch-through: 9.4 Branch -- REL_10_STABLE Details --- https://git.postgresql.org/pg/commitdiff/0d26812a4331a5bc50c1bb3115702d48d2601453 Modified Files -- src/backend/access/gin/gindatapage.c | 20

pgsql: Fix handling of empty uncompressed posting list pages in GIN

2018-07-19 Thread Alexander Korotkov
: Sivasubramanian Ramasubramanian, Alexander Korotkov Backpatch-through: 9.4 Branch -- REL9_6_STABLE Details --- https://git.postgresql.org/pg/commitdiff/44b550e0d9a5b3e4aba0211e7654b70e4f78b079 Modified Files -- src/backend/access/gin/gindatapage.c | 20

pgsql: Fix handling of empty uncompressed posting list pages in GIN

2018-07-19 Thread Alexander Korotkov
: Sivasubramanian Ramasubramanian, Alexander Korotkov Backpatch-through: 9.4 Branch -- REL9_5_STABLE Details --- https://git.postgresql.org/pg/commitdiff/3c09b032afe548a4f0c3fd0658957650c3e22832 Modified Files -- src/backend/access/gin/gindatapage.c | 20

pgsql: Fix handling of empty uncompressed posting list pages in GIN

2018-07-19 Thread Alexander Korotkov
: Sivasubramanian Ramasubramanian, Alexander Korotkov Backpatch-through: 9.4 Branch -- REL9_4_STABLE Details --- https://git.postgresql.org/pg/commitdiff/9c6a676c4cedab50e4015f49c871dbcdfc4efe07 Modified Files -- src/backend/access/gin/gindatapage.c | 20

pgsql: Fix handling of empty uncompressed posting list pages in GIN

2018-07-19 Thread Alexander Korotkov
: Sivasubramanian Ramasubramanian, Alexander Korotkov Backpatch-through: 9.4 Branch -- REL_11_STABLE Details --- https://git.postgresql.org/pg/commitdiff/608793266dbbc4f9064e6737ab3363adf9584892 Modified Files -- src/backend/access/gin/gindatapage.c | 20

pgsql: Reduce path length for locking leaf B-tree pages during insertio

2018-07-27 Thread Alexander Korotkov
. Discussion: https://postgr.es/m/CAPpHfduAMDFMNYTCN7VMBsFg_hsf0GqiqXnt%2BbSeaJworwFoig%40mail.gmail.com Author: Alexander Korotkov Reviewed-by: Yoshikazu Imai, Simon Riggs, Peter Geoghegan Branch -- master Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Fix misspelled pg_trgm contrib name in PostgreSQL 11 release not

2018-08-10 Thread Alexander Korotkov
Fix misspelled pg_trgm contrib name in PostgreSQL 11 release notes Author: Masahiko Sawada Discussion: https://postgr.es/m/CAD21AoD0Eii9y9f3cQV9AsaUF%3DMmOrQuZLHqoobFp%3DmSKEx1CA%40mail.gmail.com Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/3abc5a67edfdc568ef1b6

pgsql: Add missing documentation for argument of amcostestimate()

2018-08-10 Thread Alexander Korotkov
documentation. This commit fixes that. Discussion: https://postgr.es/m/4128fdb4-8b63-2e05-38f6-3125f8c27263%40lab.ntt.co.jp Author: Tatsuro Yamada, Alexander Korotkov Backpatch-through: 10 Branch -- master Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Add missing documentation for argument of amcostestimate()

2018-08-10 Thread Alexander Korotkov
documentation. This commit fixes that. Discussion: https://postgr.es/m/4128fdb4-8b63-2e05-38f6-3125f8c27263%40lab.ntt.co.jp Author: Tatsuro Yamada, Alexander Korotkov Backpatch-through: 10 Branch -- REL_11_STABLE Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Add missing documentation for argument of amcostestimate()

2018-08-10 Thread Alexander Korotkov
documentation. This commit fixes that. Discussion: https://postgr.es/m/4128fdb4-8b63-2e05-38f6-3125f8c27263%40lab.ntt.co.jp Author: Tatsuro Yamada, Alexander Korotkov Backpatch-through: 10 Branch -- REL_10_STABLE Details --- https://git.postgresql.org/pg/commitdiff

pgsql: Fix typo in SP-GiST error message

2018-08-10 Thread Alexander Korotkov
Fix typo in SP-GiST error message Error message didn't match the actual check. Fix that. Compression of leaf SP-GiST values was introduced in 11. So, backpatch. Discussion: https://postgr.es/m/20180810.100742.15469435.horiguchi.kyotaro%40lab.ntt.co.jp Author: Kyotaro Horiguchi Backpatch-throu

pgsql: Fix typo in SP-GiST error message

2018-08-10 Thread Alexander Korotkov
Fix typo in SP-GiST error message Error message didn't match the actual check. Fix that. Compression of leaf SP-GiST values was introduced in 11. So, backpatch. Discussion: https://postgr.es/m/20180810.100742.15469435.horiguchi.kyotaro%40lab.ntt.co.jp Author: Kyotaro Horiguchi Backpatch-throu

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Enforce cube dimension limit in all cube construction functions

2018-08-31 Thread Alexander Korotkov
Enforce cube dimension limit in all cube construction functions contrib/cube has a limit to 100 dimensions for cube datatype. However, it's not enforced everywhere, and one can actually construct cube with more than 100 dimensions having then trouble with dump/restore. This commit add checks for

pgsql: Split contrib/cube platform-depended checks into separate test

2018-08-31 Thread Alexander Korotkov
ation into separate test, making contrib/cube easier to maintain. Backpatch to all supported versions in order to make further backpatching easier. Discussion: https://postgr.es/m/CAPpHfdvJgWjxHsJTtT%2Bo1tz3OR8EFHcLQjhp-d3%2BUcmJLh-fQA%40mail.gmail.com Author: Alexander Korotkov Backpatch-through

pgsql: Implement "pg_ctl logrotate" command

2018-09-01 Thread Alexander Korotkov
Horiguchi, Alexander Kuzmenkov, Alexander Korotkov Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/ec74369931687885cfb6ce9dac55deefdb410086 Modified Files -- doc/src/sgml/maintenance.sgml | 34 +- doc/src/sgml/ref/pg_ctl-ref.sgml| 13

pgsql: Improve behavior of to_timestamp()/to_date() functions

2018-09-09 Thread Alexander Korotkov
m, while Oracle takes into account only last group of spaces/separators. Discussion: https://postgr.es/m/1873520224.1784572.1465833145330.JavaMail.yahoo%40mail.yahoo.com Author: Artur Zakirov, Alexander Korotkov, Liudmila Mantrova Review: Amul Sul, Robert Haas, Tom Lane, Dmitry Dolgov, Da

pgsql: Fix past pd_upper write in ginRedoRecompress()

2018-09-09 Thread Alexander Korotkov
ssion: https://postgr.es/m/1536091151804.6588%40amazon.com Author: Alexander Korotkov based on patch from and ideas by Sivasubramanian Ramasubramanian Review: Sivasubramanian Ramasubramanian Backpatch-through: 9.4 Branch -- master Details --- https://git.postgresql.org/pg/commi

pgsql: Fix past pd_upper write in ginRedoRecompress()

2018-09-09 Thread Alexander Korotkov
ssion: https://postgr.es/m/1536091151804.6588%40amazon.com Author: Alexander Korotkov based on patch from and ideas by Sivasubramanian Ramasubramanian Review: Sivasubramanian Ramasubramanian Backpatch-through: 9.4 Branch -- REL_11_STABLE Details --- https://git.postgresql.org/pg/commi

pgsql: Fix past pd_upper write in ginRedoRecompress()

2018-09-09 Thread Alexander Korotkov
ssion: https://postgr.es/m/1536091151804.6588%40amazon.com Author: Alexander Korotkov based on patch from and ideas by Sivasubramanian Ramasubramanian Review: Sivasubramanian Ramasubramanian Backpatch-through: 9.4 Branch -- REL_10_STABLE Details --- https://git.postgresql.org/pg/commi

pgsql: Fix past pd_upper write in ginRedoRecompress()

2018-09-09 Thread Alexander Korotkov
ssion: https://postgr.es/m/1536091151804.6588%40amazon.com Author: Alexander Korotkov based on patch from and ideas by Sivasubramanian Ramasubramanian Review: Sivasubramanian Ramasubramanian Backpatch-through: 9.4 Branch -- REL9_6_STABLE Details --- https://git.postgresql.org/pg/commi

pgsql: Fix past pd_upper write in ginRedoRecompress()

2018-09-09 Thread Alexander Korotkov
ssion: https://postgr.es/m/1536091151804.6588%40amazon.com Author: Alexander Korotkov based on patch from and ideas by Sivasubramanian Ramasubramanian Review: Sivasubramanian Ramasubramanian Backpatch-through: 9.4 Branch -- REL9_5_STABLE Details --- https://git.postgresql.org/pg/commi

pgsql: Fix past pd_upper write in ginRedoRecompress()

2018-09-09 Thread Alexander Korotkov
ssion: https://postgr.es/m/1536091151804.6588%40amazon.com Author: Alexander Korotkov based on patch from and ideas by Sivasubramanian Ramasubramanian Review: Sivasubramanian Ramasubramanian Backpatch-through: 9.4 Branch -- REL9_4_STABLE Details --- https://git.postgresql.org/pg/commi

pgsql: Add support for nearest-neighbor (KNN) searches to SP-GiST

2018-09-18 Thread Alexander Korotkov
Glukhov, Alexander Korotkov based on GSoC work by Vlad Sterzhanov Review: Andrey Borodin, Alexander Korotkov Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/2a6368343ff43743ddd90d0f4c2d0ac03e18aa85 Modified Files -- doc/src/sgml/indices.sgml

Re: pgsql: Add support for nearest-neighbor (KNN) searches to SP-GiST

2018-09-19 Thread Alexander Korotkov
On Wed, Sep 19, 2018 at 1:57 AM Alexander Korotkov wrote: > KNN > support is provided for three SP-GIST opclasses: quad_point_ops, kd_point_ops > and poly_ops (catversion is bumped). While bumping catversion I was wondering what is timezone of our catversion? Quick search over archiv

Re: pgsql: Add support for nearest-neighbor (KNN) searches to SP-GiST

2018-09-19 Thread Alexander Korotkov
On Wed, Sep 19, 2018 at 5:35 PM Tom Lane wrote: > Alexander Korotkov writes: > > While bumping catversion I was wondering what is timezone of our > > catversion? Quick search over archives didn't give me an answer. > > There's no particular convention. I th

pgsql: Fix handling of format string text characters in to_timestamp()/

2018-09-20 Thread Alexander Korotkov
Fix handling of format string text characters in to_timestamp()/to_date() cf984672 introduced improvement of handling of spaces and separators in to_timestamp()/to_date() functions. In particular, now we're skipping spaces both before and after fields. That may cause format string text character

pgsql: Replace CAS loop with single TAS in ProcArrayGroupClearXid()

2018-09-22 Thread Alexander Korotkov
Replace CAS loop with single TAS in ProcArrayGroupClearXid() Single pg_atomic_exchange_u32() is expected to be faster than loop of pg_atomic_compare_exchange_u32(). Also, it would be consistent with clog group update code. Discussion: https://postgr.es/m/CAPpHfdtxLsC-bqfxFcHswZ91OxXcZVNDBBVfg9t

pgsql: Remove extra usage of BoxPGetDatum() macro

2018-09-27 Thread Alexander Korotkov
Remove extra usage of BoxPGetDatum() macro Author: Mark Dilger Discussion: https://postgr.es/m/B2AEFCD0-836D-4654-9D59-3DF616E0A6F3%40gmail.com Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/0f6459589494a4b4ff6c707594f8d308b9da88f8 Modified Files -- sr

pgsql: Minor formatting cleanup for 2a6368343f

2018-09-27 Thread Alexander Korotkov
Minor formatting cleanup for 2a6368343f Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/4ec90f53f10141867d8b86f58d72990a13ff267b Modified Files -- src/backend/access/spgist/spgkdtreeproc.c | 6 ++ src/backend/access/spgist/spgquadtreeproc.c | 12 ++

pgsql: contrib/bloom documentation improvement

2018-10-14 Thread Alexander Korotkov
contrib/bloom documentation improvement This commit documents rounding of "length" parameter and absence of support for unique indexes and NULLs searching. Backpatch to 9.6 where contrib/bloom was introduced. Discussion: https://postgr.es/m/CAF4Au4wPQQ7EHVSnzcLjsbY3oLSzVk6UemZLD1Sbmwysy3R61g%40

pgsql: contrib/bloom documentation improvement

2018-10-14 Thread Alexander Korotkov
contrib/bloom documentation improvement This commit documents rounding of "length" parameter and absence of support for unique indexes and NULLs searching. Backpatch to 9.6 where contrib/bloom was introduced. Discussion: https://postgr.es/m/CAF4Au4wPQQ7EHVSnzcLjsbY3oLSzVk6UemZLD1Sbmwysy3R61g%40

pgsql: contrib/bloom documentation improvement

2018-10-14 Thread Alexander Korotkov
contrib/bloom documentation improvement This commit documents rounding of "length" parameter and absence of support for unique indexes and NULLs searching. Backpatch to 9.6 where contrib/bloom was introduced. Discussion: https://postgr.es/m/CAF4Au4wPQQ7EHVSnzcLjsbY3oLSzVk6UemZLD1Sbmwysy3R61g%40

pgsql: contrib/bloom documentation improvement

2018-10-14 Thread Alexander Korotkov
contrib/bloom documentation improvement This commit documents rounding of "length" parameter and absence of support for unique indexes and NULLs searching. Backpatch to 9.6 where contrib/bloom was introduced. Discussion: https://postgr.es/m/CAF4Au4wPQQ7EHVSnzcLjsbY3oLSzVk6UemZLD1Sbmwysy3R61g%40

pgsql: Add missed tag in bloom.sgml

2018-10-14 Thread Alexander Korotkov
Add missed tag in bloom.sgml Backpatch commits don't contain this error. Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/981b64f840ba81adf47ea0c34694ea416134817e Modified Files -- doc/src/sgml/bloom.sgml | 5 +++-- 1 file changed, 3 insertions(+), 2 dele

pgsql: Fix some grammar errors in bloom.sgml

2018-10-21 Thread Alexander Korotkov
Fix some grammar errors in bloom.sgml Discussion: https://postgr.es/m/CAEepm%3D3sijpGr8tXdyz-7EJJZfhQHABPKEQ29gpnb7-XSy%2B%3D5A%40mail.gmail.com Reported-by: Thomas Munro Backpatch-through: 9.6 Branch -- REL_10_STABLE Details --- https://git.postgresql.org/pg/commitdiff/28ddee2b02127a0

pgsql: Fix some grammar errors in bloom.sgml

2018-10-21 Thread Alexander Korotkov
Fix some grammar errors in bloom.sgml Discussion: https://postgr.es/m/CAEepm%3D3sijpGr8tXdyz-7EJJZfhQHABPKEQ29gpnb7-XSy%2B%3D5A%40mail.gmail.com Reported-by: Thomas Munro Backpatch-through: 9.6 Branch -- REL_11_STABLE Details --- https://git.postgresql.org/pg/commitdiff/33df118a73c099e4

pgsql: Fix some grammar errors in bloom.sgml

2018-10-21 Thread Alexander Korotkov
Fix some grammar errors in bloom.sgml Discussion: https://postgr.es/m/CAEepm%3D3sijpGr8tXdyz-7EJJZfhQHABPKEQ29gpnb7-XSy%2B%3D5A%40mail.gmail.com Reported-by: Thomas Munro Backpatch-through: 9.6 Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/31ff51adc855e3ffe8e3c20

pgsql: Fix some grammar errors in bloom.sgml

2018-10-21 Thread Alexander Korotkov
Fix some grammar errors in bloom.sgml Discussion: https://postgr.es/m/CAEepm%3D3sijpGr8tXdyz-7EJJZfhQHABPKEQ29gpnb7-XSy%2B%3D5A%40mail.gmail.com Reported-by: Thomas Munro Backpatch-through: 9.6 Branch -- REL9_6_STABLE Details --- https://git.postgresql.org/pg/commitdiff/6889428769255253

pgsql: Prevent deadlock in ginRedoDeletePage()

2018-12-12 Thread Alexander Korotkov
seems insignificant, because we only lock one page at time while traversing downlinks. Reported-by: Chen Huajun Diagnosed-by: Chen Huajun, Peter Geoghegan, Andrey Borodin Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov Backpatch

pgsql: Prevent GIN deleted pages from being reclaimed too early

2018-12-12 Thread Alexander Korotkov
store corresponding transaction id. Instead we reuse page header pd_prune_xid field, which is unused in index pages. Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Andrey Borodin, Alexander Korotkov Reviewed-by: Alexander Korotkov Backpatch-through: 9.4 B

pgsql: Fix deadlock in GIN vacuum introduced by 218f51584d5

2018-12-12 Thread Alexander Korotkov
ostgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov, based on ideas from Andrey Borodin and Peter Geoghegan Reviewed-by: Andrey Borodin Backpatch-through: 10 Branch -- REL_11_STABLE Details --- https://git.postgresql.org/pg/

pgsql: Prevent deadlock in ginRedoDeletePage()

2018-12-12 Thread Alexander Korotkov
seems insignificant, because we only lock one page at time while traversing downlinks. Reported-by: Chen Huajun Diagnosed-by: Chen Huajun, Peter Geoghegan, Andrey Borodin Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov Backpatch

pgsql: Fix deadlock in GIN vacuum introduced by 218f51584d5

2018-12-12 Thread Alexander Korotkov
ostgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov, based on ideas from Andrey Borodin and Peter Geoghegan Reviewed-by: Andrey Borodin Backpatch-through: 10 Branch -- REL_10_STABLE Details --- https://git.postgresql.org/pg/

pgsql: Prevent deadlock in ginRedoDeletePage()

2018-12-12 Thread Alexander Korotkov
seems insignificant, because we only lock one page at time while traversing downlinks. Reported-by: Chen Huajun Diagnosed-by: Chen Huajun, Peter Geoghegan, Andrey Borodin Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov Backpatch

pgsql: Prevent GIN deleted pages from being reclaimed too early

2018-12-12 Thread Alexander Korotkov
store corresponding transaction id. Instead we reuse page header pd_prune_xid field, which is unused in index pages. Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Andrey Borodin, Alexander Korotkov Reviewed-by: Alexander Korotkov Backpatch-through: 9.4 B

pgsql: Prevent deadlock in ginRedoDeletePage()

2018-12-12 Thread Alexander Korotkov
seems insignificant, because we only lock one page at time while traversing downlinks. Reported-by: Chen Huajun Diagnosed-by: Chen Huajun, Peter Geoghegan, Andrey Borodin Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov Backpatch

pgsql: Prevent GIN deleted pages from being reclaimed too early

2018-12-12 Thread Alexander Korotkov
store corresponding transaction id. Instead we reuse page header pd_prune_xid field, which is unused in index pages. Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Andrey Borodin, Alexander Korotkov Reviewed-by: Alexander Korotkov Backpatch-through: 9.4 B

pgsql: Prevent deadlock in ginRedoDeletePage()

2018-12-12 Thread Alexander Korotkov
seems insignificant, because we only lock one page at time while traversing downlinks. Reported-by: Chen Huajun Diagnosed-by: Chen Huajun, Peter Geoghegan, Andrey Borodin Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov Backpatch

pgsql: Prevent GIN deleted pages from being reclaimed too early

2018-12-12 Thread Alexander Korotkov
store corresponding transaction id. Instead we reuse page header pd_prune_xid field, which is unused in index pages. Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Andrey Borodin, Alexander Korotkov Reviewed-by: Alexander Korotkov Backpatch-through: 9.4 B

pgsql: Prevent GIN deleted pages from being reclaimed too early

2018-12-12 Thread Alexander Korotkov
store corresponding transaction id. Instead we reuse page header pd_prune_xid field, which is unused in index pages. Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Andrey Borodin, Alexander Korotkov Reviewed-by: Alexander Korotkov Backpatch-through: 9.4 B

pgsql: Fix deadlock in GIN vacuum introduced by 218f51584d5

2018-12-12 Thread Alexander Korotkov
ostgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov, based on ideas from Andrey Borodin and Peter Geoghegan Reviewed-by: Andrey Borodin Backpatch-through: 10 Branch -- master Details --- https://git.postgresql.org/pg/

pgsql: Prevent deadlock in ginRedoDeletePage()

2018-12-12 Thread Alexander Korotkov
seems insignificant, because we only lock one page at time while traversing downlinks. Reported-by: Chen Huajun Diagnosed-by: Chen Huajun, Peter Geoghegan, Andrey Borodin Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Alexander Korotkov Backpatch

pgsql: Prevent GIN deleted pages from being reclaimed too early

2018-12-12 Thread Alexander Korotkov
store corresponding transaction id. Instead we reuse page header pd_prune_xid field, which is unused in index pages. Discussion: https://postgr.es/m/31a702a.14dd.166c1366ac1.Coremail.chjischj%40163.com Author: Andrey Borodin, Alexander Korotkov Reviewed-by: Alexander Korotkov Backpatch-through: 9.4 B

pgsql: Fix wrong backpatching of ginRedoDeletePage() deadlock fix

2018-12-13 Thread Alexander Korotkov
Fix wrong backpatching of ginRedoDeletePage() deadlock fix 19cf52e6cc changes lock order in ginRedoDeletePage(). But did it in a wrong way due to oversight during backpatching. This commit fixes that. Reported-by: Bruce Momjian Discussion: https://postgr.es/m/20181213153232.GA10664%40momjian.us

pgsql: Check for conflicting queries during replay of gistvacuumpage()

2018-12-20 Thread Alexander Korotkov
ecord. So, PostgreSQL version, which doesn't know about conflict processing, will just ignore that. Reported-by: Andres Freund Diagnosed-by: Andres Freund Discussion: https://postgr.es/m/20181212224524.scafnlyjindmrbe6%40alap3.anarazel.de Author: Alexander Korotkov Backpatch-throu

pgsql: Check for conflicting queries during replay of gistvacuumpage()

2018-12-20 Thread Alexander Korotkov
ecord. So, PostgreSQL version, which doesn't know about conflict processing, will just ignore that. Reported-by: Andres Freund Diagnosed-by: Andres Freund Discussion: https://postgr.es/m/20181212224524.scafnlyjindmrbe6%40alap3.anarazel.de Author: Alexander Korotkov Backpatch-through: 9.6 Branc

pgsql: Check for conflicting queries during replay of gistvacuumpage()

2018-12-20 Thread Alexander Korotkov
ecord. So, PostgreSQL version, which doesn't know about conflict processing, will just ignore that. Reported-by: Andres Freund Diagnosed-by: Andres Freund Discussion: https://postgr.es/m/20181212224524.scafnlyjindmrbe6%40alap3.anarazel.de Author: Alexander Korotkov Backpatch-throu

  1   2   3   4   5   6   7   8   9   >