Skip to content

fix: Use bracket to release broken listener connections - #4614

Merged
steve-chavez merged 3 commits into
PostgREST:mainfrom
mkleczek:release-connections-in-retryingListen
Jan 26, 2026
Merged

fix: Use bracket to release broken listener connections#4614
steve-chavez merged 3 commits into
PostgREST:mainfrom
mkleczek:release-connections-in-retryingListen

Conversation

@mkleczek

Copy link
Copy Markdown
Collaborator

retryingListen function potentially leaks database connections. This patch ensures the connections are released in case of listen/notify errors.

retryingListen function potentially leaks database connections.
This patch ensures the connections are released in case of listen/notify errors.
@mkleczek
mkleczek force-pushed the release-connections-in-retryingListen branch from f259744 to a9f2b68 Compare January 25, 2026 18:15
Comment thread src/PostgREST/Listener.hs Outdated
Comment thread src/PostgREST/Listener.hs Outdated
retryingListen function potentially leaks database connections.
This patch ensures the connections are released in case of listen/notify errors.
@steve-chavez

steve-chavez commented Jan 26, 2026

Copy link
Copy Markdown
Member

@mkleczek Don't forget to add an entry on the CHANGELOG 🙏

Should be like: "ensure broken Listener connection are released.."

retryingListen function potentially leaks database connections.
This patch ensures the connections are released in case of listen/notify errors.
@mkleczek
mkleczek force-pushed the release-connections-in-retryingListen branch from e57a0d5 to 912afeb Compare January 26, 2026 20:59
@steve-chavez
steve-chavez merged commit 00c7cb1 into PostgREST:main Jan 26, 2026
32 checks passed
@postgrest-ci

postgrest-ci Bot commented Jan 28, 2026

Copy link
Copy Markdown

Successfully created backport PR for v14:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants