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

fix: ensure proxy shuts down gracefully on SIGTERM #877

Merged
merged 9 commits into from
Aug 11, 2021
Merged

Conversation

enocom
Copy link
Member

@enocom enocom commented Aug 9, 2021

Fixes #876

@enocom enocom requested a review from kurtisvg August 10, 2021 17:54
@enocom
Copy link
Member Author

enocom commented Aug 10, 2021

This change ended up being larger than I expected. With the calls to os.Exit, we were actually failing to run any previous defer statements.

cmd/cloud_sql_proxy/cloud_sql_proxy.go Outdated Show resolved Hide resolved
cmd/cloud_sql_proxy/cloud_sql_proxy.go Outdated Show resolved Hide resolved
cmd/cloud_sql_proxy/cloud_sql_proxy.go Show resolved Hide resolved
@enocom enocom requested a review from kurtisvg August 10, 2021 19:21
@enocom enocom changed the title fix: ensure fuse shuts down gracefully on SIGTERM fix: ensure proxy shuts down gracefully on SIGTERM Aug 10, 2021
cmd/cloud_sql_proxy/cloud_sql_proxy.go Outdated Show resolved Hide resolved
@enocom
Copy link
Member Author

enocom commented Aug 10, 2021

Ran the linting manually.

cmd/cloud_sql_proxy/cloud_sql_proxy.go Outdated Show resolved Hide resolved
@enocom enocom merged commit 9793555 into main Aug 11, 2021
@enocom enocom deleted the graceful-fuse-exit branch August 11, 2021 19:52
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 this pull request may close these issues.

The proxy doesn't shutdown gracefully when running in fuse mode
4 participants