Skip to content

Commit

Permalink
check cluster listen failed
Browse files Browse the repository at this point in the history
  • Loading branch information
sniper00 committed Jul 23, 2023
1 parent 918765c commit 3091e55
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions service/cluster.lua
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@ local function cluster_service()
assert(c.host and c.port, "require host and port")

local listenfd = socket.listen(c.host, c.port,moon.PTYPE_SOCKET_MOON)
assert(listenfd>0, strfmt("cluster listen %s:%s failed for node=%s", c.host, c.port, NODE))
socket.start(listenfd)
print(strfmt("cluster listen %s:%d", c.host, c.port))
setmetatable(clusters, {__gc=function()
Expand Down

0 comments on commit 3091e55

Please sign in to comment.