Re: About PostgreSQL as developer

Поиск
Список
Период
Сортировка
От Craig Ringer
Тема Re: About PostgreSQL as developer
Дата
Msg-id 509746C9.6090503@ringerc.id.au
обсуждение исходный текст
Ответ на Re: About PostgreSQL as developer  (Scott Marlowe <scott.marlowe@gmail.com>)
Список pgsql-general
On 11/05/2012 12:33 PM, Scott Marlowe wrote:
> On Fri, Nov 2, 2012 at 11:11 PM, Hernán Cano Martínez
> <jhernancanom@hotmail.com> wrote:
>> Hi, boys.
>> I am interested in the way of implement PostgreSQL in my apps --if
>> possible-- in a native way.
>> I am in a project that use C++ as the base programming-language.
> If you want an embedded db, you'd likely do better looking elsewhere.
> PostgreSQL's design does not lend itself to embedded work. SQLite is a
> good choice there.
Agreed. For small DBs or apps that must be portable, PostgreSQL isn't a
great choice, and it's utterly unsuitable if you want to embed the
database in-process. For that you want SQLite or Firebird.

In particular, I strongly advise you not to bundle the EnterpriseDB
installer in an application as a silent install. The poor user will
wonder where this "PostgreSQL" thing came from and might just uninstall
it. Or they might try to use it and wonder why they don't know the
passwords. They might even try to install another package that bundles
PostgreSQL, or directly install PostgreSQL for their own use, and find
out that they can't because your app has already installed it.

The standard installer version doesn't like having the data directory
moved around or having permissions messed with, doesn't like the service
account password being changed (pre-9.2), etc. It's really not ideal for
bundling in an application.

If you want to use PostgreSQL, consider distributing the .zip binaries
without the installer. Start PostgreSQL on demand with `pg_ctl` or by
installing your own service in Windows services / launchd / systemd /
etc. Run PostgreSQL on a non-standard port so you don't conflict with
any installs the user may do themselves. You'll need to check for some
common problems like the user trying to put the data directory on a
FAT32 volume, which isn't supported, but that isn't hard.

--
Craig Ringer


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

Предыдущее
От: Scott Marlowe
Дата:
Сообщение: Re: About PostgreSQL as developer
Следующее
От: "Yelai, Ramkumar IN BLR STS"
Дата:
Сообщение: Re: Parallel Insert and Delete operation