Re: Unnecessary delay in streaming replication due to replay lag

2020-08-09 Thread Masahiko Sawada
On Sun, 9 Aug 2020 at 14:54, Asim Praveen wrote: > > I would like to revive this thready by submitting a rebased patch to start > streaming replication without waiting for startup process to finish replaying > all WAL. The start LSN for streaming is determined to be the LSN that points > to th

Re: Change a constraint's index - ALTER TABLE ... ALTER CONSTRAINT ... USING INDEX ...

2020-08-09 Thread Anna Akenteva
On 2020-07-07 01:08, Tom Lane wrote: Alvaro Herrera writes: On 2020-Jul-05, Anna Akenteva wrote: -- Swapping primary key's index for an equivalent index, -- but with INCLUDE-d attributes. CREATE UNIQUE INDEX new_idx ON target_tbl (id) INCLUDE (info); ALTER TABLE target_tbl ALTER CONSTRAINT tar

Re: Add information to rm_redo_error_callback()

2020-08-09 Thread Masahiko Sawada
On Wed, 5 Aug 2020 at 00:37, Drouvot, Bertrand wrote: > > Hi hackers, > > I've attached a small patch to add information to rm_redo_error_callback(). > > The changes attached in this patch came while working on the "Add > information during standby recovery conflicts" patch (See [1]). > > The goal

Re: display offset along with block number in vacuum errors

2020-08-09 Thread Masahiko Sawada
On Fri, 7 Aug 2020 at 13:04, Amit Kapila wrote: > > On Fri, Aug 7, 2020 at 8:10 AM Masahiko Sawada > wrote: > > > > On Fri, 7 Aug 2020 at 10:49, Amit Kapila wrote: > > > > > > On Thu, Aug 6, 2020 at 7:51 PM Justin Pryzby wrote: > > > > > > > > On Thu, Aug 06, 2020 at 07:39:21PM +0530, Amit Kapi

Re: Unnecessary delay in streaming replication due to replay lag

2020-08-09 Thread Asim Praveen
> On 09-Aug-2020, at 2:11 PM, Michael Paquier wrote: > > I have not really looked at the proposed patch, but it would be good > to have some documentation. > Ah, right. The basic idea is to reuse the logic to allow read-only connections to also start WAL streaming. The patch borrows a new

Re: Allow CLUSTER, VACUUM FULL and REINDEX to change tablespace on the fly

2020-08-09 Thread Justin Pryzby
On Sun, Aug 09, 2020 at 08:02:52PM +0900, Michael Paquier wrote: > I have been looking at 0001 as a start, and your patch is incorrect on > a couple of aspects for the completion of REINDEX: > - "(" is not proposed as a completion option after the initial > REINDEX, and I think that it should. Tha

Re: 回复:how to create index concurrently on partitioned table

2020-08-09 Thread Justin Pryzby
Thanks for looking. On Sun, Aug 09, 2020 at 02:00:09PM +0900, Michael Paquier wrote: > > exactly what's needed. > > For now, I would recommend to focus first on 0001 to add support for > partitioned tables and indexes to REINDEX. CIC is much more > complicated btw, but I am not entering in the d

Re: tab completion of IMPORT FOREIGN SCHEMA

2020-08-09 Thread Tom Lane
Jeff Janes writes: > It accidentally (even before this patch) completes "IMPORT FOREIGN SCHEMA" > with a list of local schemas. This is probably wrong, but I find this > convenient as I often do this in a loop-back setup where the list of > foreign schema would be the same as the local ones. So

tab completion of IMPORT FOREIGN SCHEMA

2020-08-09 Thread Jeff Janes
I use IMPORT FOREIGN SCHEMA a bit to set up systems for testing. But not enough that I can ever remember whether INTO or FROM SERVER comes first in the syntax. Here is an improvement to the tab completion, so I don't have to keep looking it up in the docs. It accidentally (even before this patch

Optimising latch signals

2020-08-09 Thread Thomas Munro
Hi hackers, Here are some more experimental patches to reduce system calls. 0001 skips sending signals when the recipient definitely isn't waiting, using a new flag-and-memory-barrier dance. This seems to skip around 12% of the kill() calls for "make check", and probably helps with some replicat

Re: Allow CLUSTER, VACUUM FULL and REINDEX to change tablespace on the fly

2020-08-09 Thread Michael Paquier
On Sun, Apr 26, 2020 at 12:56:14PM -0500, Justin Pryzby wrote: > Rebased onto d12bdba77b0fce9df818bc84ad8b1d8e7a96614b > > Restored two tests from Alexey's original patch which exposed issue with > REINDEX DATABASE when allow_system_table_mods=off. I have been looking at 0001 as a start, and your

Re: Unnecessary delay in streaming replication due to replay lag

2020-08-09 Thread Michael Paquier
On Sun, Aug 09, 2020 at 05:54:32AM +, Asim Praveen wrote: > I would like to revive this thready by submitting a rebased patch to > start streaming replication without waiting for startup process to > finish replaying all WAL. The start LSN for streaming is determined > to be the LSN that point

Re: LSM tree for Postgres

2020-08-09 Thread Konstantin Knizhnik
On 09.08.2020 04:53, Alexander Korotkov wrote: I realize that it is not true LSM. But still I wan to notice that it is able to provide ~10 times increase of insert speed when size of index is comparable with RAM size. And "true LSM" from RocksDB shows similar results. It's very far from bein