Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Terminate electric admin endpoint #1923

Open
balegas opened this issue Nov 5, 2024 · 2 comments
Open

Terminate electric admin endpoint #1923

balegas opened this issue Nov 5, 2024 · 2 comments

Comments

@balegas
Copy link
Contributor

balegas commented Nov 5, 2024

We need a termination endpoint for Electric to cleanup storage and remove any existing replication slot.

Right now if someone wants to stop using Electric, they need to manually remove the replication slot from Postgres, otherwise WAL will keep growing.

@balegas
Copy link
Contributor Author

balegas commented Nov 5, 2024

Doesn't have to be an endpoint, can just be the terminate action

@msfstef
Copy link
Contributor

msfstef commented Nov 27, 2024

@robacourt did we end up introducing any endpoint for a controlled shutdown of a single Electric that cleans up the replication slot? If not (cause I don't see one), should we add one?

We already have an environment variable called CLEANUP_REPLICATION_SLOTS_ON_SHUTDOWN which defaults to false, that would create a temporary replication slot such that it is automatically cleaned up when electric shuts down. Perhaps this is enough for use cases where an Electric is transient, and for cases where someone wants a persistent slot between restarts we should advise they manually clean the slot?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants