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

Graceful shutdown if metrics/pprof/control service is not available #2651

Open
carpawell opened this issue Nov 16, 2023 · 0 comments
Open

Graceful shutdown if metrics/pprof/control service is not available #2651

carpawell opened this issue Nov 16, 2023 · 0 comments
Labels
enhancement Improving existing functionality I3 Minimal impact neofs-ir Inner Ring node application issues neofs-storage Storage node application issues S4 Routine U3 Regular

Comments

@carpawell
Copy link
Member

carpawell commented Nov 16, 2023

Is your feature request related to a problem? Please describe.

If some bad happens in http.Serve we just die instantly: here, here and here. These services are kinda the most important for us (they allows us understanding if the other services work in general and making decisions based on statistic information) but not that important to kill application on any error like os.Exit(1).

Describe the solution you'd like

Find out a better way to handle these errors e.g. canceling app context and waiting for other services to shutdown.

Describe alternatives you've considered

Do nothing, it works almost all the time ok.

Additional context

After #2585, #2428 and similar things, canceling context may become not the best way to do it: metrics will be the first thing to run and if they die, other services may not be inited yet (and initialization sometimes take its time and no Init takes context.Context), so no shutdown will be performed until all the Init is done.

@carpawell carpawell added enhancement Improving existing functionality neofs-ir Inner Ring node application issues neofs-storage Storage node application issues labels Nov 16, 2023
@roman-khimov roman-khimov added U3 Regular S4 Routine I3 Minimal impact labels Dec 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improving existing functionality I3 Minimal impact neofs-ir Inner Ring node application issues neofs-storage Storage node application issues S4 Routine U3 Regular
Projects
None yet
Development

No branches or pull requests

2 participants