File: stats.go

package info (click to toggle)
golang-github-influxdb-usage-client 0.0~git20151204.0.475977e-5
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 152 kB
  • sloc: makefile: 2
file content (20 lines) | stat: -rw-r--r-- 403 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package client

import "fmt"

type Stats struct {
	Product   string      `json:"-"`
	ClusterID string      `json:"cluster_id"`
	ServerID  string      `json:"server_id"`
	Data      []StatsData `json:"stats"`
}

type StatsData struct {
	Name   string `json:"name"`
	Tags   Tags   `json:"tags"`
	Values Values `json:"values"`
}

func (s Stats) Path() string {
	return fmt.Sprintf("/stats/%s", s.Product)
}