Re: dropdb --force

From: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
To: Filip Rembiałkowski <filip(dot)rembialkowski(at)gmail(dot)com>
Cc: Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: dropdb --force
Date: 2018-12-18 15:19:41
Message-ID: CAFj8pRABziXpTgipTdWQTe4acc5_BRJ0gmOtgjyrX7f_gswT4w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi

út 18. 12. 2018 v 16:11 odesílatel Filip Rembiałkowski <
filip(dot)rembialkowski(at)gmail(dot)com> napsal:

> Hi,
>
> I propose a simple patch (works-for-me), which adds --force (-f)
> option to dropdb utility.
>
> Pros: This seems to be a desired option for many sysadmins, as this
> thread proves:
> https://dba.stackexchange.com/questions/11893/force-drop-db-while-others-may-be-connected
> Cons: another possible foot-gun for the unwary.
>
> Obviously this patch needs some more work (see TODO note inside).
>
> Please share opinions if this makes sense at all, and has any chance
> going upstream.
>
> The regression tests is simplistic, please help with an example of
> multi-session test so I can follow.
>

Still one my customer use a patch that implement FORCE on SQL level. It is
necessary under higher load when is not easy to synchronize clients.

Regards

Pavel

>
>
> Thanks,
> Filip
>

Attachment Content-Type Size
drop-database-force-10.patch text/x-patch 8.3 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2018-12-18 15:24:45 Re: Some memory allocations in gin fastupdate code are a bit brain dead
Previous Message REIX, Tony 2018-12-18 15:17:28 RE: Shared Memory: How to use SYSV rather than MMAP ?