pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrey Klychkov <aaklychkov@mail.ru>
To: Victor Yegorov <vyegorov@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Subject: Re[2]: Alter index rename concurrently to
Date: Tue, 17 Jul 2018 14:48:36 +0300
Message-ID: <1531828116.497549417@f411.i.mail.ru> (raw)
In-Reply-To: <CAGnEboiyFkmGbQFAvc+tViayyPnbJkWTd93kvmhhML+cQQ_OkA@mail.gmail.com>
References: <1531767486.432607658@f357.i.mail.ru>
	<CAGnEboiyFkmGbQFAvc+tViayyPnbJkWTd93kvmhhML+cQQ_OkA@mail.gmail.com>




>Понедельник, 16 июля 2018, 22:40 +03:00 от Victor Yegorov <vyegorov@gmail.com>:
>
>пн, 16 июл. 2018 г. в 21:58, Andrey Klychkov < aaklychkov@mail.ru >:
>>I made a patch to solve this issue (see the attachment).
>>It allows to avoid locks by a query like this:
>>“alter index <new_index> rename CONCURRENTLY to <old_index_name>”.
>
>Please, have a look at previous discussions on the subject:
>- 2012  https://www.postgresql.org/message-id/CAB7nPqTys6JUQDxUczbJb0BNW0kPrW8WdZuk11KaxQq6o98PJg@mail.gmail...
>- 2013  https://www.postgresql.org/message-id/CAB7nPqSTFkuc7dZxCDX4HOTU63YXHRroNv2aoUzyD-Zz_8Z_Zg@mail.gmail...
>-  https://commitfest.postgresql.org/16/1276/
>
Hello,
Thank you for this information!

In the first discussion the concurrent alter was mentioned.
In the next link and commitfest info I only saw "Reindex concurrently 2.0".
It sounds great!
If this component will be added to core it certainly facilitates index rebuilding.

What about "alter index ... rename to" in the concurrent mode?
Does "Reindex concurrently 2.0" add it?
From time to time we need just to rename some indexes.
Without concurrent mode this "alter index" makes queues.
It may be a problem on high load databases.

-- 
Kind regards,
Andrey Klychkov


view thread (7+ messages)  latest in thread

Message-ID: <1531828116.497549417@f411.i.mail.ru>
Permalink:  ../1531828116.497549417@f411.i.mail.ru/
Also on:    postgresql.org/message-id/1531828116.497549417@f411.i.mail.ru

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: aaklychkov@mail.ru, vyegorov@gmail.com
  Subject: Re: Re[2]: Alter index rename concurrently to
  In-Reply-To: <1531828116.497549417@f411.i.mail.ru>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox