|
|
@ -3,6 +3,7 @@ package core
|
|
|
|
import (
|
|
|
|
import (
|
|
|
|
"errors"
|
|
|
|
"errors"
|
|
|
|
"fmt"
|
|
|
|
"fmt"
|
|
|
|
|
|
|
|
"git.noahlan.cn/noahlan/nnet/conn"
|
|
|
|
"git.noahlan.cn/noahlan/nnet/entity"
|
|
|
|
"git.noahlan.cn/noahlan/nnet/entity"
|
|
|
|
"git.noahlan.cn/noahlan/nnet/packet"
|
|
|
|
"git.noahlan.cn/noahlan/nnet/packet"
|
|
|
|
"git.noahlan.cn/noahlan/nnet/scheduler"
|
|
|
|
"git.noahlan.cn/noahlan/nnet/scheduler"
|
|
|
@ -268,6 +269,7 @@ func (r *connection) Close() error {
|
|
|
|
close(r.chDie)
|
|
|
|
close(r.chDie)
|
|
|
|
scheduler.PushTask(func() { Lifetime.Close(r) })
|
|
|
|
scheduler.PushTask(func() { Lifetime.Close(r) })
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
_ = r.ngin.connManager.Remove(conn.DefaultGroupName, r)
|
|
|
|
r.session.Close()
|
|
|
|
r.session.Close()
|
|
|
|
|
|
|
|
|
|
|
|
return r.conn.Close()
|
|
|
|
return r.conn.Close()
|
|
|
|