Description
Is your feature request related to a problem? Please describe.
the application may issue duplicate queries at the same time
backend A sends select a from b
, backend B also sends select a from b
at the same time
my pg will suffer from processing identical queries especially when the sql consumes disk io
Describe the solution you'd like
support holding the duplicate queries, only issue one to pg at a time, when it returns , return the same result to all clients
maybe add a set dedup = true
to only apply to certain queries
Describe alternatives you've considered
normally we do it in applications using redis lock, but we need extra storage to distribute the result, like store it in a redis key
Additional context
Add any other context or screenshots about the feature request here.