PostgREST / postgrest

REST API for any Postgres database
https://postgrest.org
MIT License
22.65k stars 1k forks source link

correct exponential backoff on Listener #3572

Closed steve-chavez closed 3 weeks ago

steve-chavez commented 3 weeks ago

Clears the limitation mentioned on https://github.com/PostgREST/postgrest/pull/3536

The Listener no longer uses the https://hackage.haskell.org/package/retry package and instead uses a much simpler IORef in AppState for the delays.

Additionally it no longer uses exception throwing/catching, which is rather messy and brings some concerns (https://github.com/PostgREST/postgrest/issues/3569#issuecomment-2146013327).

steve-chavez commented 3 weeks ago

codecov fails because of missing tests for LISTEN recovery. I've put this is a TODO on https://github.com/PostgREST/postgrest/issues/1766#issuecomment-2150021160