Re: Async IO HTTP server frontend for PostgreSQL - Mailing list pgsql-general

From Steve Atkins
Subject Re: Async IO HTTP server frontend for PostgreSQL
Date
Msg-id 7A16102C-83BE-4643-8E3A-3ECC578FE6A3@blighty.com
Whole thread Raw
In response to Re: Async IO HTTP server frontend for PostgreSQL  (Dmitriy Igrishin <dmitigr@gmail.com>)
Responses Re: Async IO HTTP server frontend for PostgreSQL  (Dmitriy Igrishin <dmitigr@gmail.com>)
List pgsql-general
On Sep 10, 2014, at 12:16 AM, Dmitriy Igrishin <dmitigr@gmail.com> wrote:

> Hello, David
>
> 2014-09-10 4:31 GMT+04:00 David Boreham <david_list@boreham.org>:
> Hi Dmitriy, are you able to say a little about what's driving your quest for async http-to-pg ?
> I'm curious as to the motivations, and whether they match up with some of my own reasons for wanting to use
low-thread-countsolutions. 
> For many web projects I consider Postgres as a development platform. Thus,
> I prefer to keep the business logic (data integrity trigger functions and
> API functions) in the database. Because of nature of the Web, many concurrent
> clients can request a site and I want to serve maximum possible of them with
> minimal overhead. Also I want to avoid a complex solutions. So, I believe that
> with asynchronous solution it's possible to *stream* the data from the database
> to the maximum number of clients (which possible can request my site over a
> slow connection).

That's going to require you to have one database connection open for each
client. If the client is over a slow connection it'll keep the database connection
open far longer than is needed, (compared to the usual "pull data from the
database as fast as the disks will go, then spoonfeed it out to the slow client"
approach). Requiring a live database backend for every open client connection
doesn't seem like a good idea if you're supporting many slow concurrent clients.

Cheers,
  Steve



pgsql-general by date:

Previous
From: Dmitriy Igrishin
Date:
Subject: Re: Async IO HTTP server frontend for PostgreSQL
Next
From: Dmitriy Igrishin
Date:
Subject: Re: Async IO HTTP server frontend for PostgreSQL