优化节点进程退出逻辑

This commit is contained in:
GoEdgeLab
2022-09-02 16:12:58 +08:00
parent 397b79e47c
commit a98889d48c
7 changed files with 53 additions and 32 deletions

View File

@@ -16,6 +16,7 @@ func TestIPListDB_AddItem(t *testing.T) {
if err != nil {
t.Fatal(err)
}
err = db.AddItem(&pb.IPItem{
Id: 1,
IpFrom: "192.168.1.101",
@@ -45,6 +46,12 @@ func TestIPListDB_AddItem(t *testing.T) {
if err != nil {
t.Fatal(err)
}
err = db.Close()
if err != nil {
t.Fatal(err)
}
t.Log("ok")
}