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 shutdown server context cancel error #281

Merged
merged 1 commit into from
Feb 11, 2022

Conversation

laraws
Copy link
Contributor

@laraws laraws commented Feb 11, 2022

When I used the source code to build the podsync, after run the ./podsync command, I used ctrl+c to stop the server, then the log display the server shutdown failed, the detailed log displayed below:

INFO[2022-02-10T10:50:36+08:00] shutting down web server                     
ERRO[2022-02-10T10:50:36+08:00] server shutdown failed                        error="context canceled"
INFO[2022-02-10T10:50:36+08:00] shutting down cron                           
INFO[2022-02-10T10:50:36+08:00] Got compaction priority: {level:0 score:1.73 dropPrefixes:[]} 
INFO[2022-02-10T10:50:36+08:00] gracefully stopped                           

So I fixed this error. And the log displays like this now:

INFO[2022-02-11T11:32:42+08:00] shutting down web server                     
INFO[2022-02-11T11:32:42+08:00] shutting down cron                           
INFO[2022-02-11T11:32:42+08:00] Got compaction priority: {level:0 score:1.73 dropPrefixes:[]} 
INFO[2022-02-11T11:32:42+08:00] Running for level: 0                         
INFO[2022-02-11T11:32:42+08:00] LOG Compact 0->1, del 1 tables, add 1 tables, took 2.300744ms 
INFO[2022-02-11T11:32:42+08:00] Compaction for level: 0 DONE                 
INFO[2022-02-11T11:32:42+08:00] Force compaction on level 0 done             
INFO[2022-02-11T11:32:42+08:00] gracefully stopped

@mxpv mxpv merged commit eedb6ba into mxpv:main Feb 11, 2022
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.

2 participants