Re: 8.4.1 ubuntu karmic slow createdb

From: Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com>
To: Nikolas Everett <nik9000(at)gmail(dot)com>
Cc: jd(at)commandprompt(dot)com, Andres Freund <andres(at)anarazel(dot)de>, pgsql-performance(at)postgresql(dot)org, Michael Clemmons <glassresistor(at)gmail(dot)com>
Subject: Re: 8.4.1 ubuntu karmic slow createdb
Date: 2009-12-11 21:57:56
Message-ID: dcc563d10912111357k538816baybbfdbe3b846f7aa3@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-performance

On Fri, Dec 11, 2009 at 2:39 PM, Nikolas Everett <nik9000(at)gmail(dot)com> wrote:
>
>
> On Fri, Dec 11, 2009 at 3:50 PM, Joshua D. Drake <jd(at)commandprompt(dot)com>
> wrote:
>>
>> On Fri, 2009-12-11 at 15:43 -0500, Nikolas Everett wrote:
>> > Turning fsync off on a dev database is a bad idea?  Sure you might
>> > kill it and have to start over, but thats kind of the point in a dev
>> > database.
>>
>> My experience is that bad dev practices turn into bad production
>> practices, whether intentionally or not.
>
> Fair enough.  I'm of the opinion that developers need to have their unit
> tests run fast.  If they aren't fast then your just not going to test as
> much as you should.  If your unit tests *have* to createdb then you have to
> do whatever you have to do to get it fast.  It'd probably be better if unit
> tests don't create databases or alter tables at all though.

This is my big issue. dropping / creating databases for unit tests is
overkill. Running any DDL at all for a unit test seems wrong to me
too. Insert a row if you need it, MAYBE. Unit tests should work with
a test database that HAS the structure and database already in place.

What happens if your unit tests get lose in production and drop a
database, or a table. Not good.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Scott Mead 2009-12-11 21:59:43 Re: 8.4.1 ubuntu karmic slow createdb
Previous Message Robert Haas 2009-12-11 21:41:36 Re: Adding support for SE-Linux security

Browse pgsql-performance by date

  From Date Subject
Next Message Scott Mead 2009-12-11 21:59:43 Re: 8.4.1 ubuntu karmic slow createdb
Previous Message Nikolas Everett 2009-12-11 21:39:34 Re: 8.4.1 ubuntu karmic slow createdb