Re: Open Source tool to deploy/promote PostgreSQL DDL

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Ron <ronljohnsonjr(at)gmail(dot)com>, pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Open Source tool to deploy/promote PostgreSQL DDL
Date: 2018-07-11 23:48:40
Message-ID: c10d61b5-c2a1-5292-1684-f5d653ca6e5d@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 07/11/2018 04:01 PM, Ron wrote:
> On 07/11/2018 04:10 PM, Christopher Browne wrote:
> [snip]
>> ITIL surely does NOT specify the use of database rollback scripts as
>> THE SPECIFIED MECHANISM for a backout procedure.
>>
>> In practice, we tend to take database snapshots using filesystem
>> tools, as that represents a backout procedure that will work regardless
>> of the complexity of an upgrade.
>>
>> It is quite possible for an upgrade script to not be reversible.
>>
>> After all, not all matrices are invertible; there are a surprisingly
>> large
>> number of preconditions that are required for that in linear algebra.
>>
>> And in databases, not all upgrades may be reversed via rollback scripts.
>
> Does "rollback script" truly mean undoing what you just did in a
> transaction-like manner?
>

Hard to say without knowing the system you are using, but I would guess
no. I use Sqitch and it uses the term revert:

https://metacpan.org/pod/sqitchtutorial#Status,-Revert,-Log,-Repeat

which I think is more accurate. I find it very handy feature when in
development mode. Write script --> deploy --> test, if fails --> revert,
rewrite deploy script --> deploy and so on.

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message tirveni yadav 2018-07-12 02:44:04 Re: Open Source tool to deploy/promote PostgreSQL DDL
Previous Message Ron 2018-07-11 23:01:08 Re: Open Source tool to deploy/promote PostgreSQL DDL