Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wHxhC-007f4s-0b for pgsql-general@arkaria.postgresql.org; Wed, 29 Apr 2026 05:42:50 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wHxhA-001stb-03 for pgsql-general@arkaria.postgresql.org; Wed, 29 Apr 2026 05:42:48 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wHxh9-001stS-2G for pgsql-general@lists.postgresql.org; Wed, 29 Apr 2026 05:42:47 +0000 Received: from mail-pl1-x636.google.com ([2607:f8b0:4864:20::636]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wHxh7-00000003k1E-1ziV for pgsql-general@postgresql.org; Wed, 29 Apr 2026 05:42:47 +0000 Received: by mail-pl1-x636.google.com with SMTP id d9443c01a7336-2b45cb89f7eso75959475ad.0 for ; Tue, 28 Apr 2026 22:42:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1777441363; x=1778046163; darn=postgresql.org; h=mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=2OERcBokVvGwhSCzEmkmQvH7/uY35mqw8hUJ+jklib8=; b=ByTxHaKv8eUz+JDkFhRNirLzBxx/ZNkVgfujGqyD0AdwGlTp7woxhSpvZgymr0RnCF BfXTuDg/FoNuf3aV55dkniaR+b+A4OmWIUNQ11grcM9onfbX1x2op6Q9ikarkDkThef8 J6l+Rgqq2UuGCWmVA/W8fyF1jQJyV8jvy/rZSreB35V5WlotGYrpj3CpbZTO8ynlG9zp fC+mhKcxv/E8AIAclj2SZrM5W3UVXQajiJtUgW7GU+Bum15Nkuh4uKcN5srn50mqqZvc IcYDpgP7aqVsR6LcOSI4ndDHc1I/Hl9NzKHWkk9q9kcbXpS/EEjDkCZhjQPXkabLgfzw WpJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777441363; x=1778046163; h=mime-version:subject:references:in-reply-to:message-id:to:from:date :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=2OERcBokVvGwhSCzEmkmQvH7/uY35mqw8hUJ+jklib8=; b=MMsQmtv8Trrl4Th9e/9juFJzNhPFcwfglA4NLNBBJvXL38cuqUkxEUIrZhWHMhhNa0 6Rw09y/fezjY0SjwlB4oVWOFW+mOFigcpG/t/Iu8so8I28J9v++gsf9ew3sLE9C3TdBU /Et8FLJa4kNAJIPinRI5vKzuw3pkPR2+im6ETKHagNvSfE2NkqdyFb9L2Fo8E+1J5eF3 qTpF6Azn97UrFeYxexEqvdaEe9K2lW8sSh1OKXuk1fKPbqCSSrXrplMAp6yZoeeO3jmO qr9XnDZBeSycQj8r8UmCiZ6r8hvZUAW/1n8n/syKXaK1/oNpDCH8NCcoJG92PKnBFVjm OczA== X-Forwarded-Encrypted: i=1; AFNElJ9TMujU0MRp6qx6ychykl04fTtq6fbiRHWhvcYXIrKoe+lU64dUjl6vAqNjgdSW7xMk81DZRe5vQJmQaTRS@postgresql.org X-Gm-Message-State: AOJu0YzbuBbfOoFTi2NcS3P5xZemO5zHXUf3bGWWFbF/pvL1SRef4r92 eYDeIs9wjhdK5AvwM7BzAwNMxohS/OSWCGhKtoFSRN5Ed+dzzOHhnlGx X-Gm-Gg: AeBDies/4QhHsHUgrFGqrIuFZKuZ2esyI3FZmpB29a75OKCDCFXP3ZySdixz5NC7PXy sui612fFZafMYqehxaLVt2Ym2VAUq8PfscmwIWSyaJz6mjk9925DVuUdu+CO2VTmdYy3ed3QHG0 PXaUGWmPHMXUaMLhJ+EFpTh6vlw46Nw/Ywh2fR2rtDIPTeOypjV6GtaVpv3KzqOH/wj406nXdBL SsFq7/wRPoj7Ou/fyATUfM5LmEkjaa8XYMB7Nk5SDphrBNmF/kXKkmJXOeBYEpNgY7DzLQutvCs 9vlUN0jllhgl37k8VmHk4JOYhvlTt+RLVWB35ScKVr1OcWvvPftalNQBnicdj1DO78lODoKYmXJ 8lpkmTQeUGxueUZShfLFhJIVe8vRQSA3q4amMSN/nKNbpW+Clk/ZtWPa16UC7IfoBlBJHqAVXDj dHjgfMiVaUrU1Wj+ZZXizr4DGvhcRZFk3GVMsfvt3Rliwsg3QuuUURNPnsHGHz6VMfujkn2LlEx 9R7Yc3V X-Received: by 2002:a17:903:3c48:b0:2b4:61cc:37a8 with SMTP id d9443c01a7336-2b97c452764mr60753455ad.17.1777441363139; Tue, 28 Apr 2026 22:42:43 -0700 (PDT) Received: from [192.168.1.110] (60-240-79-46.static.tpgi.com.au. [60.240.79.46]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2b98897edefsm9155725ad.74.2026.04.28.22.42.40 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 Apr 2026 22:42:42 -0700 (PDT) Date: Wed, 29 Apr 2026 15:42:31 +1000 From: Guyren Howe To: Laurenz Albe , PostgreSQL General Message-ID: <39f640d6-2a39-48c2-90b0-4adffe63bfc7@Spark> In-Reply-To: References: <4237964E-B88B-4F6B-AD3D-FD67C17ED480@relevantlogic.com> Subject: Re: Describing the natural architecture for an internet-facing Postgres based app: feedback sought X-Readdle-Message-ID: 39f640d6-2a39-48c2-90b0-4adffe63bfc7@Spark MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="69f19a4c_ce19105_29b7" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --69f19a4c_ce19105_29b7 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Thanks for the feedback. If you=E2=80=99re doing a small business application, running code in the= database isn=E2=80=99t a concern. If you=E2=80=99re doing a larger application, you=E2=80=99re probably sha= rding anyway. If you have more database servers and fewer web servers, is= that actually an issue=3F Updated the piece to discuss this. On 28 Apr 2026 at 15:20 +1000, Laurenz Albe ,= wrote: > On Tue, 2026-04-28 at 13:24 +1000, guyren=40relevantlogic.com wrote: > > Coming from a Rails/PHP/etc world. All of those communities generally= hold that > > the database should be treated as a dumb data bucket with all the log= ic in the middleware. > > > > I=E2=80=99ve long thought someone should write up what the alternativ= e architecture using > > Postgres to its fullest would look like. In order to differentiate it= , I start from > > the security advantages and work forward. > > > > I=E2=80=99d love to get some feedback on it. Harsh criticism is most = useful=E2=80=A6 :-) > > No harsh critizism, but I am wary of all extremist positions. > Just as I think that it is silly to keep the database as dumb as possib= le, > I doubt that it is a good position to put all the smarts into the datab= ase. > > One obvious disadvantage is that if you put much of the processing into= > the database, most of the load will be on the database server, which is= > difficult to scale. > > Why not let each component do what it is best at=3F > > Yours, > Laurenz Albe --69f19a4c_ce19105_29b7 Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline
Thanks for the feedback.
&=23160;
If you=E2=80=99re doing a small business application, running code i= n the database isn=E2=80=99t a concern.
&=23160;
If you=E2=80=99re doing a larger application, you=E2=80=99re probabl= y sharding anyway. If you have more database servers and fewer web server= s, is that actually an issue=3F
&=23160;
Updated the piece to discuss this.
On 28 Apr 2026 at 15:20 +1000, Laur= enz Albe <laurenz.albe=40cybertec.at>, wrote:
On Tue, 2026-04-28 at 13:24 +1000, guyren=40= relevantlogic.com wrote:
Coming from a Rails/PHP/etc world. All of those communities gen= erally hold that
the database should be treated as a dumb data bucket with all the logic i= n the middleware.

I=E2=80=99ve long thought someone should write up what the alternative ar= chitecture using
Postgres to its fullest would look like. In order to differentiate it, I = start from
the security advantages and work forward.

I=E2=80=99d love to get some feedback on it. Harsh criticism is most usef= ul=E2=80=A6 :-)

No harsh critizism, but I am wary of all extremist positions.
Just as I think that it is silly to keep the database as dumb as possible= ,
I doubt that it is a good position to put all the smarts into the databas= e.

One obvious disadvantage is that if you put much of the processing into the database, most of the load will be on the database server, which is difficult to scale.

Why not let each component do what it is best at=3F

Yours,
Laurenz Albe
--69f19a4c_ce19105_29b7--