From b700426a3b7b41a9a6289b6330499a3da2cdd7a2 Mon Sep 17 00:00:00 2001 From: Martin Geno Date: Thu, 12 May 2016 17:43:23 +0200 Subject: [PATCH] add Flags and MeshviewerStatistics for old meshviewer nodes.json --- models/meshviewerstatistics.go | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 models/meshviewerstatistics.go diff --git a/models/meshviewerstatistics.go b/models/meshviewerstatistics.go new file mode 100644 index 0000000..7572590 --- /dev/null +++ b/models/meshviewerstatistics.go @@ -0,0 +1,26 @@ +package models + +import "github.com/FreifunkBremen/respond-collector/data" + +type MeshviewerStatistics struct { + NodeId string `json:"node_id"` + Clients uint32 `json:"clients"` + RootFsUsage float64 `json:"rootfs_usage,omitempty""` + LoadAverage float64 `json:"loadavg,omitempty""` + Memory data.Memory `json:"memory,omitempty""` + Uptime float64 `json:"uptime,omitempty""` + Idletime float64 `json:"idletime,omitempty""` + Gateway string `json:"gateway,omitempty"` + Processes struct { + Total uint32 `json:"total"` + Running uint32 `json:"running"` + } `json:"processes,omitempty""` + MeshVpn *data.MeshVPN `json:"mesh_vpn,omitempty"` + Traffic struct { + Tx *data.Traffic `json:"tx"` + Rx *data.Traffic `json:"rx"` + Forward *data.Traffic `json:"forward"` + MgmtTx *data.Traffic `json:"mgmt_tx"` + MgmtRx *data.Traffic `json:"mgmt_rx"` + } `json:"traffic,omitempty""` +}