Re: glibc qsort() vulnerability

2024-02-09 Thread Andrey Borodin
instruction? These cpus are really neat things... so, probably, yes, it does. Best regards, Andrey Borodin.

Re: Transaction timeout

2024-01-31 Thread Andrey Borodin
> On 31 Jan 2024, at 14:27, Japin Li wrote: > > LGTM. > > If there is no other objections, I'll change it to ready for committer > next Monday. I think we have a quorum, so I decided to go ahead and flipped status to RfC. Thanks! Best regards, Andrey Borodin.

Re: MultiXact\SLRU buffers configuration

2024-01-26 Thread Andrey Borodin
> On 20 Jan 2024, at 08:31, vignesh C wrote: > > On Mon, 9 Jan 2023 at 09:49, Andrey Borodin wrote: >> >> On Tue, Jan 3, 2023 at 5:02 AM vignesh C wrote: >>> does not apply on top of HEAD as in [1], please post a rebased patch: >>> >&g

Re: SLRU optimization - configurable buffer pool and partitioning the SLRU lock

2024-01-26 Thread Andrey Borodin
something like that actually happens. If possible, I'd prefer one lock at a time, any maybe sometimes two-three with some guarantees that this is safe. So, from my POV first solution that you proposed seems much better to me. Thanks for working on this! Best regard, Andrey Borodin.

Re: UUID v7

2024-01-24 Thread Andrey Borodin
63c3741922a5 But again, UUIDs are not designed to store timestamp. They are unique and v7 promote data locality via time-ordering. Best regards, Andrey Borodin.

Re: UUID v7

2024-01-19 Thread Andrey Borodin
> On 19 Jan 2024, at 13:25, Andrey Borodin wrote: > > Also, I've added some documentation on all functions. Here's v12. Changes: 1. Documentation improvements 2. Code comments 3. Better commit message and reviews list Best regards, Andrey Borodin. v12-0001-Implement-UUID

Re: UUID v7

2024-01-19 Thread Andrey Borodin
ind of confusing behaviour. I've changed it to more expected version. Also, I've added some documentation on all functions. Best regards, Andrey Borodin. v11-0001-Implement-UUID-v7-as-per-IETF-draft.patch Description: Binary data

Re: UUID v7

2024-01-18 Thread Andrey Borodin
> On 18 Jan 2024, at 20:39, Andrey Borodin wrote: > > But 16455577420ns after 1582-10-15 00:00:00 UTC was 2022-02-22 19:22:22 > UTC. And that was 2022-02-23 00:22:22 in UTC-05. '2022-02-22 19:22:22 UTC' is exactly that moment which was encoded into example UUIDs. It's

Re: UUID v7

2024-01-18 Thread Andrey Borodin
is expected to be generated on "Tuesday, February 22, 2022 2:22:22.00 PM GMT-05:00". It's exaplained to be 16455577420ns after 1582-10-15 00:00:00 UTC. But 16455577420ns after 1582-10-15 00:00:00 UTC was 2022-02-22 19:22:22 UTC. And that was 2022-02-23 00:22:22 in UTC-05. Best regards, Andrey Borodin.

Re: UUID v7

2024-01-18 Thread Andrey Borodin
own. What is left: deal with timezones, improve documentation. Best regards, Andrey Borodin. [0] https://datatracker.ietf.org/doc/html/draft-ietf-uuidrev-rfc4122bis#name-example-of-a-uuidv1-value v10-0001-Implement-UUID-v7-as-per-IETF-draft.patch Description: Binary data

Re: UUID v7

2024-01-16 Thread Andrey Borodin
do you think? Best regards, Andrey Borodin. v9-0001-Implement-UUID-v7-as-per-IETF-draft.patch Description: Binary data

Re: Proposal to add page headers to SLRU pages

2023-12-07 Thread Andrey Borodin
moved to shared buffers as proposedelsewhere [1].Thread that I cited stopped in 2018 for this exact reason. 5 years ago. Is this argument still valid?Meanwhile checksums of buffer pages also reside on a page :)Best regards, Andrey Borodin.

Re: UUID v7

2023-10-09 Thread Andrey Borodin
quence rollover. Well, the current patch will just use now()+1ms when 2^18 is exhausted. Even if now() would be passed as an argument (however current patch does not support an argument). Best regards, Andrey Borodin.

Re: psql \watch 2nd argument: iteration count

2023-04-06 Thread Andrey Borodin
first result not \watch. I did not know that. Well, I knew it in parts, but did not understand as a whole. Thanks! Best regards, Andrey Borodin.

Re: Add "host" to startup packet

2023-04-02 Thread Andrey Borodin
new feature has, some documentation and test must be included. You can judge from recently committed libpq load balancing what it takes to add a connection option [0]. But, obviously, it makes sense to discuss it before going all the way of implementation.Best regards, Andrey Borodin.[0] https://github.com/postgres/postgres/commit/7f5b1981

Re: regression coverage gaps for gist and hash indexes

2023-03-31 Thread Andrey Borodin
geDelete() is not exercised, and is worth fixing IMO. Simply adding 10x more data in gist.sql helps, but I think we can do something more clever... Best regards, Andrey Borodin.

Re: psql \watch 2nd argument: iteration count

2023-03-24 Thread Andrey Borodin
atch. Done. > > + > +If number of iterations is specified - query will be executed only > +given number of times. > + > > Is it common to use "-" here? I think using comma like > "If number of iterations is specified, " > i

Re: Amcheck verification of GiST and GIN

2023-03-17 Thread Andrey Borodin
. Because it's an epsilon-comparison, ε=1.0E-06. GiST might miss newly inserted data, because the "adjusted" tuple was "same" if data is in proximity of 0.01 of any previously indexed point, but out of known MBRs. I'll try to reproduce this tomorrow, so far no luck. Best regards, Andrey Borodin.

Re: psql \watch 2nd argument: iteration count

2023-03-16 Thread Andrey Borodin
the documentation. Done. > With an interval in place, we could now automate some tests with > \watch where it does not fail. What do you think about adding a test > with a simple query, an interval of 0s and one iteration? Done. Also found a bug that we actually were doing N+1 iterations. Thank you for working on this! Best regards, Andrey Borodin. v9-0001-Iteration-count-argument-to-psql-watch-command.patch Description: Binary data

Re: psql \watch 2nd argument: iteration count

2023-03-14 Thread Andrey Borodin
single message. I'd rather still keep the > three tests, though, as they check the three conditions upon which the > error would be triggered. PFA v8. Thanks! Best regards, Andrey Borodin. v8-0001-Fix-incorrect-argument-handling-in-psql-watch.patch Description: Binary data v8-0002-Add-itera

Re: psql \watch 2nd argument: iteration count

2023-03-13 Thread Andrey Borodin
On Mon, Mar 13, 2023 at 5:26 PM Michael Paquier wrote: > > I have tweaked things as bit as of the attached, and ran pgindent. > What do you think? > Looks good to me. Thanks! Best regards, Andrey Borodin.

Re: psql \watch 2nd argument: iteration count

2023-03-12 Thread Andrey Borodin
Michael, thanks for reviewing this! On Sun, Mar 12, 2023 at 6:17 PM Michael Paquier wrote: > > On Sun, Mar 12, 2023 at 01:05:39PM -0700, Andrey Borodin wrote: > > In the review above Kyotaro-san suggested that message should contain > > information on what it ex

Re: psql \watch 2nd argument: iteration count

2023-03-12 Thread Andrey Borodin
uffer(query_buf); > + return PSQL_CMD_ERROR; > > Is this missing psql_scan_reset(scan_state)? Yes, fixed. Best regards, Andrey Borodin. v5-0002-Add-iteration-count-argument-to-psql-watch-comman.patch Description: Binary data v5-0001-Fix-incorrect-argument-handling-in-psql-watch.patch Description: Binary data

Re: psql \watch 2nd argument: iteration count

2023-03-08 Thread Andrey Borodin
as available. > Yes, that makes sense! Thanks! Best regards, Andrey Borodin. v4-0002-Add-iteration-count-argument-to-psql-watch-comman.patch Description: Binary data v4-0001-Fix-incorrect-argument-handling-in-psql-watch.patch Description: Binary data

Re: [EXTERNAL] Re: Support load balancing in libpq

2023-03-02 Thread Andrey Borodin
ense in case of shuffling arrays inplace. It is important only for making a new copy of an array and only in languages that cannot access uninitialized values. I'd suggest just removing this line (in both cases). Best regards, Andrey Borodin.

Re: psql \watch 2nd argument: iteration count

2023-02-26 Thread Andrey Borodin
think we should do > the same for iteration counts. +1, done. > Additionally, we need to update the > documentation. Done. Thanks for the review! Best regards, Andrey Borodin. v3-0002-Add-iteration-count-argument-to-psql-watch-comman.patch Description: Binary data v3-0001-Fix-incorrec

Re: psql \watch 2nd argument: iteration count

2023-02-20 Thread Andrey Borodin
t; That should probably be fixed. > > And should probably be independent patches. > PFA 2 independent patches. Also, I've fixed a place to break after an iteration. Now if we have e.g. 2 iterations - there will be only 1 sleep time. Thanks! Best regards, Andrey Borodin. v2

Re: [PATCH] Add pretty-printed XML output option

2023-02-16 Thread Andrey Borodin
tected from using external XML namespaces? What if the user passes some xmlns that will force it to read namespace data from the server filesystem? Or is it not possible? I see there are a lot of calls to xml_parse() anyway, but still... Best regards, Andrey Borodin.

psql \watch 2nd argument: iteration count

2023-02-16 Thread Andrey Borodin
lso, if we do not provide a timespan, 2 seconds are selected. But if we provide an incorrect argument - 1 second is selected. PFA the patch that adds iteration count argument and makes timespan argument more consistent. What do you think? Best regards, Andrey Borodin. 0001-Add-iteration-count-argum

Re: Add connection active, idle time to pg_stat_activity

2023-02-16 Thread Andrey Borodin
test that verifies delta for select some_counter from pg_stat_session where pid = pg_backend_pid(); 4. Macroses like PGSTAT_IS_RUNNING do not look like net win in code readability and PGSTAT prefix have no semantic load. That's all I've found so far. Thank you! Best regards, Andrey Borodin. PS. W

Re: Silent overflow of interval type

2023-02-15 Thread Andrey Borodin
rflow checks in the nearby code of timestamp.c, I'd say that this case should not be an exception. By chance did you look at all other nearby cases, is it the only place with overflow? (I took a look too, but haven't found anything suspicious) Best regards, Andrey Borodin.

Re: Buffer usage detailed by RelKind in EXPLAIN ANALYZE BUFFERS

2023-02-13 Thread Andrey Borodin
when called gazillion times per second. Best regards, Andrey Borodin. for godbolt.cpp Description: Binary data

Re: Buffer usage detailed by RelKind in EXPLAIN ANALYZE BUFFERS

2023-02-13 Thread Andrey Borodin
's > already quite expensive... > I think collection of instrumentation is done unconditionally. We always do that pgBufferUsage.shared_blks_hit++; when the buffer is in shared_buffers. Best regards, Andrey Borodin.

Buffer usage detailed by RelKind in EXPLAIN ANALYZE BUFFERS

2023-02-13 Thread Andrey Borodin
by query, but they have little practical sense too. All in all I do not have an opinion if this feature is a good tradeoff. What do you think? Does the feature look useful? Do we want a more polished implementation? Thanks! Best regards, Andrey Borodin. v1-0001-Split-EXPLAIN-ANALYZE-BUFFERS-by-RelKind.patch Description: Binary data

Re: pglz compression performance, take two

2023-02-13 Thread Andrey Borodin
just reject it and I'll get back to this during summer. Best regards, Andrey Borodin.

Re: UUID v7

2023-02-10 Thread Andrey Borodin
ring value to users. However, I agree that eager users can just have it today as an extension and be happy with it [0]. Maybe it's fine to wait a year for others... Best regards, Andrey Borodin. [0] https://github.com/x4m/pg_uuid_next

UUID v7

2023-02-10 Thread Andrey Borodin
avis, authors of the standard cc Kirk Wolak and Nik Samokhvalov who requested the feature Thanks! Best regards, Andrey Borodin. [0] https://datatracker.ietf.org/doc/html/draft-peabody-dispatch-new-uuid-format-04 v1-0001-Implement-UUID-v7-as-per-IETF-draft.patch Description: Binary data

Re: Too coarse predicate locks granularity for B+ tree indexes

2023-02-07 Thread Andrey Borodin
}' to get a commit by date from rev-parse. Best regards, Andrey Borodin.

Re: pglz compression performance, take two

2023-02-06 Thread Andrey Borodin
. And so far I failed to extract input\outputs of that odd case, because it is buried under so many layers of abstraction and affects only late stats. Maybe the problem is not in compression at all... Best regards, Andrey Borodin.

Re: pglz compression performance, take two

2023-02-05 Thread Andrey Borodin
On Sun, Feb 5, 2023 at 5:51 PM Tomas Vondra wrote: > > On 2/5/23 19:36, Andrey Borodin wrote: > > On Fri, Jan 6, 2023 at 10:02 PM Andrey Borodin > > wrote: > >> > >> Hello! Please find attached v8. > > > > I got some interesting feedback f

Re: pglz compression performance, take two

2023-02-05 Thread Andrey Borodin
On Fri, Jan 6, 2023 at 10:02 PM Andrey Borodin wrote: > > Hello! Please find attached v8. I got some interesting feedback from some patch users. There was an oversight that frequently yielded results that are 1,2 or 3 bytes longer than expected. Looking closer I found that the corre

Re: Amcheck verification of GiST and GIN

2023-02-04 Thread Andrey Borodin
e's the current version. Thank you! Best regards, Andrey Borodin. v23-0001-Refactor-amcheck-to-extract-common-locking-routi.patch Description: Binary data v23-0002-Add-gist_index_check-function-to-verify-GiST-ind.patch Description: Binary data v23-0003-Add-gin_index_parent_check-to-verify-

Re: How to implement read operations for my own access method?

2023-02-04 Thread Andrey Borodin
ou can see my free lectures about details of implementation of built-in access methods [2]. Also, I can offer you my PGCon talk "Index DIY" about forking GiST into extension [3]. Thank you! Best regards, Andrey Borodin. [0] https://www.postgresql.org/docs/current/xindex.html [1] http

Re: BUG: Postgres 14 + vacuum_defer_cleanup_age + FOR UPDATE + UPDATE

2023-02-04 Thread Andrey Borodin
ew parent of the deleted page. Even then we cannot end up with infinite index scan - we will just make one extra loop. Although, IndexScan will yield duplicate tids. In case of interference with concurrent insertion we will get a tree structure departed from optimal, but that is not a problem. Best regards, Andrey Borodin.

Re: Something is wrong with wal_compression

2023-01-27 Thread Andrey Borodin
. Best regards, Andrey Borodin.

Re: Something is wrong with wal_compression

2023-01-26 Thread Andrey Borodin
, maybe, add an amcheck run. As far as I recollect, this test was introduced to test this new function in 857ee8e391f. Best regards, Andrey Borodin.

Re: Something is wrong with wal_compression

2023-01-26 Thread Andrey Borodin
nteger);". Best regards, Andrey Borodin. [0] https://www.postgresql.org/message-id/flat/565FB155-C6B0-41E2-8C44-7B514DC25132%2540yandex-team.ru [1] https://www.postgresql.org/message-id/flat/20210313012820.GJ29463%40telsasoft.com#0f18d3a4d593ea656fdc761e026fee81

Re: Experiments with Postgres and SSL

2023-01-18 Thread Andrey Borodin
possible first bytes that clearly indicates that this is a TLS connection or not? Best regards, Andrey Borodin.

Re: Amcheck verification of GiST and GIN

2023-01-13 Thread Andrey Borodin
On Fri, Jan 13, 2023 at 7:35 PM Jose Arthur Benetasso Villanova wrote: > > Hello again. I see the change. Thanks > Thanks! I also found out that there was a CI complaint about amcheck.h not including some necessary stuff. Here's a version with a fix for that. Best regards, Andrey Borod

Re: Amcheck verification of GiST and GIN

2023-01-13 Thread Andrey Borodin
e find the attached fixed version. Thank you! Best regards, Andrey Borodin. v20-0001-Refactor-amcheck-to-extract-common-locking-routi.patch Description: Binary data v20-0003-Add-gin_index_parent_check-to-verify-GIN-index.patch Description: Binary data v20-0002-Add-gist_index_parent_check-f

Re: Transaction timeout

2023-01-13 Thread Andrey Borodin
ow(), clock_timestamp(), pg_sleep(3) \watch 1". I doubt patch really contains arithmetic errors. Many thanks for looking into this! Best regards, Andrey Borodin.

Re: Transaction timeout

2023-01-12 Thread Andrey Borodin
On Thu, Jan 12, 2023 at 11:24 AM Nathan Bossart wrote: > > On Sun, Dec 18, 2022 at 12:53:31PM -0800, Andrey Borodin wrote: > > I've rewritten this part to correctly report all timeouts that did > > happen. However there's now a tricky comma-formatting code which was > &

Re: MultiXact\SLRU buffers configuration

2023-01-11 Thread Andrey Borodin
Hi Dilip! Thank you for the review! On Tue, Jan 10, 2023 at 9:58 PM Dilip Kumar wrote: > > On Mon, Jan 9, 2023 at 9:49 AM Andrey Borodin wrote: > > > > On Tue, Jan 3, 2023 at 5:02 AM vignesh C wrote: > > > does not apply on top of HEAD as in [1], please post a reba

Re: MultiXact\SLRU buffers configuration

2023-01-08 Thread Andrey Borodin
On Tue, Jan 3, 2023 at 5:02 AM vignesh C wrote: > does not apply on top of HEAD as in [1], please post a rebased patch: > Thanks! Here's the rebase. Best regards, Andrey Borodin. v24-0001-Divide-SLRU-buffers-into-8-associative-banks.patch Description: Binary data

Re: Amcheck verification of GiST and GIN

2023-01-08 Thread Andrey Borodin
On Sun, Jan 8, 2023 at 8:05 PM Andrey Borodin wrote: > > Please find the attached new version. In this patchset heapallindexed > flag is removed from GIN checks. > Uh... sorry, git-formatted wrong branch. Here's the correct version. Double checked. Best regards, Andrey Borodin.

Re: Amcheck verification of GiST and GIN

2023-01-08 Thread Andrey Borodin
Hi Jose, thank you for review and sorry for so long delay to answer. On Wed, Dec 14, 2022 at 4:19 AM Jose Arthur Benetasso Villanova wrote: > > > On Sun, 27 Nov 2022, Andrey Borodin wrote: > > > On Sun, Nov 27, 2022 at 1:29 PM Andrey Borodin > > wrote: > >>

Re: pglz compression performance, take two

2023-01-06 Thread Andrey Borodin
On Sun, Nov 27, 2022 at 10:43 AM Andrey Borodin wrote: > > PFA review fixes (step 1 is unchanged). Hello! Please find attached v8. Changes are mostly cosmetic: 1. 2 steps from previous message were squashed together 2. I tried to do a better commit message Thanks! Best regards, Andrey B

Re: GROUP BY ALL

2023-01-06 Thread Andrey Borodin
in the fact that it's an SQL extension, not a standard... Best regards, Andrey Borodin.

Re: XID formatting and SLRU refactorings (was: Add 64-bit XIDs into PostgreSQL 15)

2023-01-05 Thread Andrey Borodin
use my incompetence in the topic, but maybe some commit message or comments would help. What kind of xact segments conversion we do? Why is it only necessary for xacts, but not other SLRUs? Thank you for working on this important project! Best regards, Andrey Borodin.

Re: MultiXact\SLRU buffers configuration

2022-12-20 Thread Andrey Borodin
On Sat, Jul 23, 2022 at 1:48 AM Thomas Munro wrote: > > On Sat, Jul 23, 2022 at 8:41 PM Andrey Borodin wrote: > > Thomas, do you still have any doubts? Or is it certain that SLRU will be > > replaced by any better subsystem in 16? > > Hi Andrey, > >

Re: GROUP BY ALL

2022-12-18 Thread Andrey Borodin
PRISE ME". I mean I see some cases when it's useful and much less cases when it's dangerously ambiguous. E.g. grouping by result of a subquery looks way too complex and unpredictable. But with simple Vars... what could go wrong? Best regards, Andrey Borodin.

GROUP BY ALL

2022-12-18 Thread Andrey Borodin
nk? Best regards, Andrey Borodin. [0] https://www.linkedin.com/posts/mosha_duckdb-firebolt-snowflake-activity-7009615821006131200-VQ0o/ v1-0001-Implement-GROUP-BY-ALL.patch Description: Binary data

Re: Transaction timeout

2022-12-18 Thread Andrey Borodin
On Wed, Dec 7, 2022 at 1:30 PM Andrey Borodin wrote: > I hope to address other feedback on the weekend. Andres, here's my progress on working with your review notes. > > @@ -3277,6 +3282,7 @@ ProcessInterrupts(void) > >*/ > >

Re: Transaction timeout

2022-12-07 Thread Andrey Borodin
On Wed, Dec 7, 2022 at 10:23 AM Andres Freund wrote: > > On 2022-12-03 09:41:04 -0800, Andrey Borodin wrote: > > Fixed. Added test for this. > > The tests don't pass: https://cirrus-ci.com/build/4811553145356288 > oops, sorry. Here's the fix. I hope to address other feedback

Re: Transaction timeout

2022-12-05 Thread Andrey Borodin
gt; > ahprintf(AH, "SET lock_timeout = 0;\n"); > > ahprintf(AH, "SET idle_in_transaction_session_timeout = 0;\n"); > > + ahprintf(AH, "SET transaction_timeout = 0;\n"); > > Hm - why is that the right thing to do? Because transaction_timeout has effects of statement_timeout. Thank you! Best regards, Andrey Borodin.

Re: Transaction timeout

2022-12-03 Thread Andrey Borodin
transaction_timeout simultaneously. Currently there's a lot of code around this... Thanks! Best regards, Andrey Borodin. v2-0001-Intorduce-transaction_timeout.patch Description: Binary data

Transaction timeout

2022-12-02 Thread Andrey Borodin
the feature for testing by him, and it seems straightforward. Please find attached. If it's not known to be a bad idea - we'll work on it. Thanks! Best regards, Andrey Borodin. [0] https://www.postgresql.org/message-id/flat/763A0689-F189-459E-946F-F0EC4458980B%40hotmail.com v1-0001-Intorduce

Re: An attempt to avoid locally-committed-but-not-replicated-to-standby-transactions in synchronous replication

2022-11-29 Thread Andrey Borodin
problem. But I'd propose to treat these two points differently, they possess drastically different scales of danger. Query Cancels are issued here and there during failovers\switchovers. Crash amidst network partitioning is not that common. Best regards, Andrey Borodin.

Re: An attempt to avoid locally-committed-but-not-replicated-to-standby-transactions in synchronous replication

2022-11-28 Thread Andrey Borodin
interest and agreement. Best regards, Andrey Borodin. [0] https://wiki.postgresql.org/wiki/PgCon_2020_Developer_Unconference/Edge_cases_of_synchronous_replication_in_HA_solutions [1] https://archive.fosdem.org/2021/schedule/event/postgresql_caveats_of_replication/attachments/slides/4365/expo

Re: Amcheck verification of GiST and GIN

2022-11-27 Thread Andrey Borodin
On Sun, Nov 27, 2022 at 1:29 PM Andrey Borodin wrote: > > GiST verification checks only one invariant that can be verified if > page locks acquired the same way as page split does. > GIN does not require ShareLock because it does not check cross-level > invariants. > I was wro

Re: Amcheck verification of GiST and GIN

2022-11-27 Thread Andrey Borodin
mated way, look into this file t/001_verify_heapam.pl. Surely we can write these tests. At least automate what you have just done in the review. However, committing similar checks is a very tedious work: something will inevitably turn buildfarm red as a watermelon. I hope I'll post a version w

Re: An attempt to avoid locally-committed-but-not-replicated-to-standby-transactions in synchronous replication

2022-11-27 Thread Andrey Borodin
On Tue, Nov 8, 2022 at 9:06 PM Andrey Borodin wrote: > > On Thu, Sep 29, 2022 at 3:53 PM Bruce Momjian wrote: > > > > So, what happens when an insufficient number of synchronous replicas > > reply? > > It's a failover. > > > Sessions hang because the synchr

Re: Use fadvise in wal replay

2022-11-27 Thread Andrey Borodin
ormance benefit shows up only when readahead is disabled. And on many workloads readahead brings unneeded data into page cache, so it's preferred configuration. In this particular case, time to apply WAL decreases from 53s to 33s. Thanks! Best Regards, Andrey Borodin.

Re: pglz compression performance, take two

2022-11-27 Thread Andrey Borodin
d_match about traversing the history seems too > early - it's before handling invalid entries and cleanup, but it does > not talk about that at all, and the actual while loop is after that. Yes, this seems right for me. PFA review fixes (step 1 is unchanged). I did not include next_id->next

Re: libpq compression (part 2)

2022-11-17 Thread Andrey Borodin
form {no_compression_name, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL} 3. Comments like "Return true if should, false if should not." are useless. Thanks! Best regards, Andrey Borodin.

Re: libpq compression (part 2)

2022-11-16 Thread Andrey Borodin
o keep_going; to start from the beginning of the message. Thank you! Best regards, Andrey Borodin.

Re: libpq compression (part 2)

2022-11-14 Thread Andrey Borodin
On Sat, Nov 12, 2022 at 8:04 PM Andrey Borodin wrote: > > While testing patch some more I observe unpleasant segfaults: > > #27 0x0b08fda2 in lz4_decompress (d_stream=0x18cf82a0, > src=0x7feae4fa505d, src_size=92, > (gdb) select-frame 27 > (gdb) info locals >

Re: libpq compression (part 2)

2022-11-12 Thread Andrey Borodin
On Sat, Nov 12, 2022 at 1:47 PM Andrey Borodin wrote: > > I've tried the patch, it works as advertised. While testing patch some more I observe unpleasant segfaults: #26 0x7fecafa1e058 in __memcpy_ssse3_back () from target:/lib64/libc.so.6 #27 0x0b08fda2 in lz4_decompress (d_

Re: Use fadvise in wal replay

2022-11-12 Thread Andrey Borodin
On Sun, Aug 7, 2022 at 9:41 AM Andrey Borodin wrote: > Hi everyone. The patch is 16 lines, looks harmless and with proven benefits. I'm moving this into RfC. Thanks! Best regards, Andrey Borodin.

Re: libpq compression (part 2)

2022-11-12 Thread Andrey Borodin
mpression anyway. What do you think? Also, compression is a very cool and awaited feature, hope to see it committed one day, thank you for working on this! Best regards, Andrey Borodin.

Re: An attempt to avoid locally-committed-but-not-replicated-to-standby-transactions in synchronous replication

2022-11-08 Thread Andrey Borodin
e used by hanging queries. Best regards, Andrey Borodin.

Re: pg_stat_statements locking

2022-09-12 Thread Andrey Borodin
> On 12 Sep 2022, at 23:01, Tom Lane wrote: > > Andrey Borodin writes: >>> On 12 Sep 2022, at 18:18, Julien Rouhaud wrote: >>> That being >>> said I don't know if adding a timeout would be too expensive for the lwlock >>> infrastructure. > &g

Re: pg_stat_statements locking

2022-09-12 Thread Andrey Borodin
. Best regards, Andrey Borodin.

Re: pg_stat_statements locking

2022-09-12 Thread Andrey Borodin
ould be useful anyway. Best regards, Andrey Borodin.

pg_stat_statements locking

2022-09-12 Thread Andrey Borodin
uld not occur if tuplestore did not convert into on-disk representation. But I don't see how to reliably protect from this. What do you think? Thank! Best regards, Andrey Borodin. v1-0001-Demonstrate-and-fix-lock-of-all-SQL-queries-by-pg.patch Description: Binary data

Re: Support for Rust

2022-09-10 Thread Andrey Borodin
Rust pros. I just think this can be of interest to someone new to Rust (like me). Best regards, Andrey Borodin. [0] https://buildfarm.postgresql.org/cgi-bin/show_members.pl

Re: Extensible storage manager API - smgr hooks

2022-08-25 Thread Andrey Borodin
provide same extension for Postgres if this technology (extensible smgr) is in core. Does such an extension seem useful for Postgres? Or does this data access pattern seems unusual for Postgres? By pattern I mean vast amounts of cold data only ever appended and never touched. Best regard

Re: pg_stat_wal: tracking the compression effect

2022-08-25 Thread Andrey Borodin
oubt it have enough runway on 1 block to show off. If only we could persist compression context between many pages... Compression ratio may be different on different workloads, so system view or something similar could be of use. Thanks! Best regards, Andrey Borodin.

Re: MultiXact\SLRU buffers configuration

2022-08-17 Thread Andrey Borodin
> On 17 Aug 2022, at 00:36, i.laza...@postgrespro.ru wrote: > >> Andrey Borodin wrote 2022-07-23 11:39: >> Yura, thank you for your benchmarks! >> We already knew that patch can save the day on pathological workloads, >> now we have a proof of this. >> Als

Re: Amcheck verification of GiST and GIN

2022-08-17 Thread Andrey Borodin
> On 23 Jul 2022, at 14:40, Andrey Borodin wrote: > > Done. PFA attached patchset. > > Best regards, Andrey Borodin. > Here's v13. Changes: 1. Fixed passing through downlink in GIN index 2. Fixed GIN tests (one test case was not working) Thanks to Vitaliy Kukharik for t

Re: Logical WAL sender unresponsive during decoding commit

2022-08-16 Thread Andrey Borodin
check. > I think it should be backpatched. Yes, I think so too. > [1] > https://www.postgresql.org/message-id/CAD21AoD%2BaNfLje%2B9JOqWbTiq1GL4BOp9_f7FxLADm8rS8cDhCQ%40mail.gmail.com The patch in this thread looks good to me. Thank you! Best regards, Andrey Borodin.

Logical WAL sender unresponsive during decoding commit

2022-08-15 Thread Andrey Borodin
:4167 #16 ServerLoop () at ./build/../src/backend/postmaster/postmaster.c:1725 #17 0x56177123954b in PostmasterMain (argc=9, argv=0x561771ab70e0) at ./build/../src/backend/postmaster/postmaster.c:1398 #18 0x561770fae8b6 in main (argc=9, argv=0x561771ab70e0) at ./build/../src/backend/main/main.

Re: something has gone wrong, but what is it?

2022-08-10 Thread Andrey Borodin
o MyBackendType = B_INVALID; after PANIC or ERROR? Best regards, Andrey Borodin.

Re: Use fadvise in wal replay

2022-08-07 Thread Andrey Borodin
nt type. > > Thoughts? Thomas expressed this idea upthread. Benchmarks done by Jakub showed that this approach had no significant improvement over existing master code. The same benchmarks showed almost x1.5 improvement of readahead in 8Kb or 128Kb chunks. Best regards, Andrey Borodin.

Re: Use fadvise in wal replay

2022-08-05 Thread Andrey Borodin
Hi Bharath, thank you for the suggestion. > On 5 Aug 2022, at 16:02, Bharath Rupireddy > wrote: > > On Thu, Aug 4, 2022 at 9:48 PM Andrey Borodin wrote: >> >>> On 18 Jul 2022, at 22:55, Robert Haas wrote: >>> >>> On Thu, Jun 23, 2022 at

Re: Use fadvise in wal replay

2022-08-04 Thread Andrey Borodin
asic approach should be here, though. Actually, the only question is offset from current read position: should it be 1 block or full readehead chunk. Again, this does not change anything, just a matter of choice. Thanks! Best regards, Andrey Borodin.

Re: Slow standby snapshot

2022-08-02 Thread Andrey Borodin
> On 2 Aug 2022, at 20:18, Simon Riggs wrote: > > On Tue, 2 Aug 2022 at 12:32, Andrey Borodin wrote: > >> KnownAssignedXidsRemoveTree() only compress with probability 1/8, but it is >> still O(N*N). > > Currently it is O(NlogS), not quite as bad as O(N^2).

Re: Slow standby snapshot

2022-08-02 Thread Andrey Borodin
IMO original patch (with next pointer) is much safer in terms of unexpected performance degradation. Thanks! Best regards, Andrey Borodin.

Re: [Commitfest 2022-07] Patch Triage: Waiting on Author

2022-07-28 Thread Andrey Borodin
uld not mark patch as RwF and move it to next CF instead. Thank you! Best regards, Andrey Borodin.

Re: Slow standby snapshot

2022-07-26 Thread Andrey Borodin
> On 20 Jul 2022, at 02:12, Michail Nikolaev wrote: > >> I've looked into v5. > Thanks! > > Patch is updated accordingly your remarks. The patch seems Ready for Committer from my POV. Thanks! Best regards, Andrey Borodin.

  1   2   3   4   5   6   7   >