mirror of
https://github.com/cloudwu/skynet.git
synced 2026-07-24 20:23:06 +00:00
add skynet.stat() to get cpu cost and message count
This commit is contained in:
@@ -634,11 +634,15 @@ function skynet.start(start_func)
|
||||
end
|
||||
|
||||
function skynet.endless()
|
||||
return c.command("ENDLESS")~=nil
|
||||
return (c.intcommand("STAT", "endless") == 1)
|
||||
end
|
||||
|
||||
function skynet.mqlen()
|
||||
return c.intcommand "MQLEN"
|
||||
return c.intcommand("STAT", "mqlen")
|
||||
end
|
||||
|
||||
function skynet.stat(what)
|
||||
return c.intcommand("STAT", what)
|
||||
end
|
||||
|
||||
function skynet.task(ret)
|
||||
|
||||
Reference in New Issue
Block a user