HangfireIO / HangfireIO/Hangfire
Force shutdown?
- Dominant language
- C#
- Stars
- 10.1k
- Forks
- 1.8k
- Avg merge
- 1h 19m
- Merged PRs (30d)
- 1
Description
Is there a way to force Hangfire to shutdown? We are using the AppBuilderExtensions UseHangfireServer method to bootstrap hangfire.
During deploy we sometimes need to drop the Hangfire database (SQL server) and when we do it starts generating a lot of errors as it can no longer access the database. That is all fine but we would prefer to shutdown the hangfire server before dropping the database to avoid errors clogging up our logs. After the drop/db migration is complete we need to tell the Hangfire server to start again. Is this possible?
Contributor guide
Research direction
Start with the AppBuilderExtensions.UseHangfireServer method and trace how the Hangfire server is started and disposed during deployment. Determine whether a supported stop-and-restart control can avoid database access while migrations run; done should include a documented way to stop the server, drop or migrate the SQL Server database, and start it again without log-flooding errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100