(优发娱乐平台) Tornado add_callback_from_signal 和 add_callback 的区别是什么?

tornado ioloop中有add_callback和add_callback_from_signal两个方法,不知道两者的差别是什么?

文档又不是没有写:

Safe for use from a Python signal handler; should not be used otherwise.

Callbacks added with this method will be run without any stack_context, to avoid picking up the context of the function that was interrupted by the signal.

发表评论

电子邮件地址不会被公开。 必填项已用*标注