Re: Horizontal scalability/sharding

Поиск
Список
Период
Сортировка
От Marc Munro
Тема Re: Horizontal scalability/sharding
Дата
Msg-id 1441067303.18680.26.camel@bloodnok.com
обсуждение исходный текст
Ответ на Horizontal scalability/sharding  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-hackers
On Mon, 2015-08-31 at 22:21 +0000,  Robert Haas wrote:

> It seems to me that sharding consists of (1) breaking your data set up
> into shards, (2) possibly replicating some of those shards onto
> multiple machines, and then (3) being able to access the remote data
> from local queries. [...]

I believe there is another aspect to sharding that I have not yet seen
mentioned, which is one of connection routing.

One use case that I have been involved in, is to simply partition the
application into entirely, or almost entirely, separate datasets running
on separate databases with little or no need for queries to access
remote data.

This allows each database to deal only with connections from clients
that actually want its local data, greatly reducing the number of
connections on any individual database.  If this works for your
application, your ability to scale is great.

The pain point comes from trying to route queries to the correct
database.  Inevitably, everyone taking this route builds custom
connection-selection layers into their apps.

It seems to me that even with the more sophisticated types of sharding
being discussed here, the ability to conditionally route a
query/connection to a suitable starting database could be quite
beneficial.

Although this is probably a job for the pgbouncer/pgpool developers
rather than the hackers on this list, this thread seems to be a good
place to mention it.

__
Marc





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

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: Horizontal scalability/sharding
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Horizontal scalability/sharding