Re: update with no changes - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: update with no changes
Date
Msg-id aa7e80d2-699c-e626-c96f-44781be1e01e@dunslane.net
Whole thread Raw
In response to Re: update with no changes  (Marcos Pegoraro <marcos@f10.com.br>)
Responses Re: update with no changes
List pgsql-hackers
On 11/19/21 12:57, Marcos Pegoraro wrote:
>
>     I get the idea of letting the server centralize logic like this -
>     but frankly if the application is choosing to send all that data
>     across the wire just to have the server throw it away the
>     application is wasting network I/O.  If it does manage its
>     resources carefully then the server will never even see an update
>     and its behavior here becomes moot.
>
> I understand your point, it´s responsability of application to do what
> it has to do. But lots of times (maybe 98% of them) is not same people
> doing server side and application side. So, Postgres guys will have to
> review all code being done on apps ?
>
> And ok, thanks for explaining me.


suppress_redundant_updates_trigger was created precisely because it's
not always easy to create application code in such a way that it
generates no redundant updates. However, there is a cost to using it,
and the break even point can be surprisingly high. It should therefore
be used with caution, and after appropriate benchmarks.


cheers


andrew

--
Andrew Dunstan
EDB: https://www.enterprisedb.com




pgsql-hackers by date:

Previous
From: Bharath Rupireddy
Date:
Subject: rename SnapBuild* macros in slot.c
Next
From: Marcos Pegoraro
Date:
Subject: Re: update with no changes