Re: Template for schema? (as opposed to databases)

From: Dominique Devienne <ddevienne(at)gmail(dot)com>
To: Francisco Olarte <folarte(at)peoplecall(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Template for schema? (as opposed to databases)
Date: 2022-01-11 16:53:30
Message-ID: CAFCRh-8xr5r2K3ZO7Jz5a1EoZnxTv1OFCaZPRf_auvK7jbmZdw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Jan 11, 2022 at 5:38 PM Francisco Olarte <folarte(at)peoplecall(dot)com>
wrote:

> On Tue, 11 Jan 2022 at 17:10, Dominique Devienne <ddevienne(at)gmail(dot)com>
> wrote:
> ...
> > Creating the first two "fixed" schemas is fast enough. 300ms, including
> populating the 2nd with a bunch of rows.
> > But creating the 3rd kind, which will be done many times, is not so
> fast, at 2.5 - 3s, which may seem fast,
> > but when you do it dozens of time in unit-tests, adds up quickly to slow
> running tests...
>
> First question would be, are you running a test server?

No. This is a "site" server, used by everyone. Devs and testers / users.

> Are you testing crashes of just application logic?
>

Well, I try to write code that does not crash :)
But yes, it's testing results of running the code are as expected.

> For these I normally use wal_level=minimal, fsync=off, same as for
> full cluster restores ( it is faster to redo it if restore fails,
> reinitdb on test cases ), it normally gives quite a nice performance boost.
>

I'm well versed in libpq, not so much in server admin.
The server is "remote" and "just runs", and I connect to it... --DD

In response to

Browse pgsql-general by date

  From Date Subject
Next Message David G. Johnston 2022-01-11 16:58:45 Re: Template for schema? (as opposed to databases)
Previous Message Dominique Devienne 2022-01-11 16:50:02 Re: Template for schema? (as opposed to databases)