Skip to content

Conversation

@Lensual
Copy link
Contributor

@Lensual Lensual commented Jul 16, 2024

from #78


kill -9 is not recommend, syscall.Kill SIGTERM instead of.

@sunshinexcode
Copy link
Contributor

@Lensual
syscall.Kill 能正常 kill 掉进程吗? 我这边等有空了, 再验证一下, 没问题的话, 可以合入

@Lensual
Copy link
Contributor Author

Lensual commented Jul 17, 2024

@sunshinexcode
syscall.Kill 原理上和 kill 命令是一样的,但是这里我把 9 SIGKILL 换成了 15 SIGTERM 。SIGTERM 允许进程执行正常退出流程,关闭资源、完成io同步等,而SIGKILL会立即、强制杀死进程。

Copy link
Contributor

@sunshinexcode sunshinexcode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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.

3 participants