当工作进程正常退出,被杀死,或者手工关闭(例如worker.disconnect())时会调用。 disconnect和exit事件间可能存在延迟。
我们已经定义了一组简单的命令:connect登录到数据库,disconnect注销并select发送SQL查询并获得结果。所有结果都通过返回rbuf。
%%%testcases...all()->[start_and_stop,config,connect_and_disconnect].
Event:'disconnect' 父进程或子进程中调用.disconnect()方法后触发这个事件。断开后不会在互发消息,并且.connected属性值为false。
disconnect_event(callback_id)[source] 通过其ID(返回connect_event)断开回叫。
调用erlang:disconnect_node(Node)强制断开节点。 当前连接到的(visible)节点的列表由返回nodes()。

扫码关注腾讯云开发者
领取腾讯云代金券
Copyright © 2013 - 2026 Tencent Cloud. All Rights Reserved. 腾讯云 版权所有
深圳市腾讯计算机系统有限公司 ICP备案/许可证号:粤B2-20090059
粤公网安备44030502008569号
腾讯云计算(北京)有限责任公司 京ICP证150476号 | 京ICP备11018762号
