Re: PostgreSQL as a local in-memory cache

Поиск
Список
Период
Сортировка
От Pierre C
Тема Re: PostgreSQL as a local in-memory cache
Дата
Msg-id op.vegjnqfreorkce@apollo13
обсуждение исходный текст
Ответ на Re: PostgreSQL as a local in-memory cache  (Josh Berkus <josh@agliodbs.com>)
Список pgsql-performance
> Especially as, in repeated tests, PostgreSQL with persistence turned off
> is just as fast as the fastest nondurable NoSQL database.  And it has a
> LOT more features.

An option to completely disable WAL for such use cases would make it a lot
faster, especially in the case of heavy concurrent writes.

> Now, while fsync=off and tmpfs for WAL more-or-less eliminate the IO for
> durability, they don't eliminate the CPU time.

Actually the WAL overhead is some CPU and lots of locking.

> Which means that a caching version of PostgreSQL could be even faster.
> To do that, we'd need to:
>
> a) Eliminate WAL logging entirely
> b) Eliminate checkpointing
> c) Turn off the background writer
> d) Have PostgreSQL refuse to restart after a crash and instead call an
> exteral script (for reprovisioning)
>
> Of the three above, (a) is the most difficult codewise.

Actually, it's pretty easy, look in xlog.c


В списке pgsql-performance по дате отправления:

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: PostgreSQL as a local in-memory cache
Следующее
От: Dimitri Fontaine
Дата:
Сообщение: Re: PostgreSQL as a local in-memory cache