implemented the pts feature in the server side as well
This commit is contained in:
@ -76,6 +76,7 @@ type json_out_server_stats struct {
|
||||
ServerPeers int64 `json:"server-peers"`
|
||||
|
||||
SshProxySessions int64 `json:"pxy-ssh-sessions"`
|
||||
ServerPtsSessions int64 `json:"server-pts-sessions"`
|
||||
}
|
||||
|
||||
// this is a more specialized variant of json_in_notice
|
||||
@ -911,6 +912,7 @@ func (ctl *server_ctl_stats) ServeHTTP(w http.ResponseWriter, req *http.Request)
|
||||
stats.ServerRoutes = s.stats.routes.Load()
|
||||
stats.ServerPeers = s.stats.peers.Load()
|
||||
stats.SshProxySessions = s.stats.ssh_proxy_sessions.Load()
|
||||
stats.ServerPtsSessions = s.stats.pts_sessions.Load()
|
||||
status_code = WriteJsonRespHeader(w, http.StatusOK)
|
||||
if err = je.Encode(stats); err != nil { goto oops }
|
||||
|
||||
|
Reference in New Issue
Block a user