| 1 | // SPDX-License-Identifier: GPL-3.0-or-later |
| 2 | |
| 3 | package tengine |
| 4 | |
| 5 | import "github.com/netdata/netdata/go/plugins/plugin/framework/collectorapi" |
| 6 | |
| 7 | type ( |
| 8 | // Charts is an alias for collectorapi.Charts |
| 9 | Charts = collectorapi.Charts |
| 10 | // Dims is an alias for collectorapi.Dims |
| 11 | Dims = collectorapi.Dims |
| 12 | ) |
| 13 | |
| 14 | var charts = Charts{ |
| 15 | { |
| 16 | ID: "bandwidth_total", |
| 17 | Title: "Bandwidth", |
| 18 | Units: "B/s", |
| 19 | Fam: "bandwidth", |
| 20 | Ctx: "tengine.bandwidth_total", |
| 21 | Type: collectorapi.Area, |
| 22 | Dims: Dims{ |
| 23 | {ID: "bytes_in", Name: "in", Algo: collectorapi.Incremental}, |
| 24 | {ID: "bytes_out", Name: "out", Algo: collectorapi.Incremental, Mul: -1}, |
| 25 | }, |
| 26 | }, |
| 27 | { |
| 28 | ID: "connections_total", |
| 29 | Title: "Connections", |
| 30 | Units: "connections/s", |
| 31 | Fam: "connections", |
| 32 | Ctx: "tengine.connections_total", |
| 33 | Dims: Dims{ |
| 34 | {ID: "conn_total", Name: "accepted", Algo: collectorapi.Incremental}, |
| 35 | }, |
| 36 | }, |
| 37 | { |
| 38 | ID: "requests_total", |
| 39 | Title: "Requests", |
| 40 | Units: "requests/s", |
| 41 | Fam: "requests", |
| 42 | Ctx: "tengine.requests_total", |
| 43 | Dims: Dims{ |
| 44 | {ID: "req_total", Name: "processed", Algo: collectorapi.Incremental}, |
| 45 | }, |
| 46 | }, |
| 47 | { |
| 48 | ID: "requests_per_response_code_family_total", |
| 49 | Title: "Requests Per Response Code Family", |
| 50 | Units: "requests/s", |
| 51 | Fam: "requests", |
| 52 | Ctx: "tengine.requests_per_response_code_family_total", |
| 53 | Type: collectorapi.Stacked, |
| 54 | Dims: Dims{ |
| 55 | {ID: "http_2xx", Name: "2xx", Algo: collectorapi.Incremental}, |
| 56 | {ID: "http_5xx", Name: "5xx", Algo: collectorapi.Incremental}, |
| 57 | {ID: "http_3xx", Name: "3xx", Algo: collectorapi.Incremental}, |
| 58 | {ID: "http_4xx", Name: "4xx", Algo: collectorapi.Incremental}, |
| 59 | {ID: "http_other_status", Name: "other", Algo: collectorapi.Incremental}, |
| 60 | }, |
| 61 | }, |
| 62 | { |
| 63 | ID: "requests_per_response_code_detailed_total", |
| 64 | Title: "Requests Per Response Code Detailed", |
| 65 | Units: "requests/s", |
| 66 | Ctx: "tengine.requests_per_response_code_detailed_total", |
| 67 | Fam: "requests", |
| 68 | Type: collectorapi.Stacked, |
| 69 | Dims: Dims{ |
| 70 | {ID: "http_200", Name: "200", Algo: collectorapi.Incremental}, |
| 71 | {ID: "http_206", Name: "206", Algo: collectorapi.Incremental}, |
| 72 | {ID: "http_302", Name: "302", Algo: collectorapi.Incremental}, |
| 73 | {ID: "http_304", Name: "304", Algo: collectorapi.Incremental}, |
| 74 | {ID: "http_403", Name: "403", Algo: collectorapi.Incremental}, |
| 75 | {ID: "http_404", Name: "404", Algo: collectorapi.Incremental}, |
| 76 | {ID: "http_416", Name: "419", Algo: collectorapi.Incremental}, |
| 77 | {ID: "http_499", Name: "499", Algo: collectorapi.Incremental}, |
| 78 | {ID: "http_500", Name: "500", Algo: collectorapi.Incremental}, |
| 79 | {ID: "http_502", Name: "502", Algo: collectorapi.Incremental}, |
| 80 | {ID: "http_503", Name: "503", Algo: collectorapi.Incremental}, |
| 81 | {ID: "http_504", Name: "504", Algo: collectorapi.Incremental}, |
| 82 | {ID: "http_508", Name: "508", Algo: collectorapi.Incremental}, |
| 83 | {ID: "http_other_detail_status", Name: "other", Algo: collectorapi.Incremental}, |
| 84 | }, |
| 85 | }, |
| 86 | { |
| 87 | ID: "requests_upstream_total", |
| 88 | Title: "Number Of Requests Calling For Upstream", |
| 89 | Units: "requests/s", |
| 90 | Fam: "upstream", |
| 91 | Ctx: "tengine.requests_upstream_total", |
| 92 | Dims: Dims{ |
| 93 | {ID: "ups_req", Name: "requests", Algo: collectorapi.Incremental}, |
| 94 | }, |
| 95 | }, |
| 96 | { |
| 97 | ID: "tries_upstream_total", |
| 98 | Title: "Number Of Times Calling For Upstream", |
| 99 | Units: "calls/s", |
| 100 | Fam: "upstream", |
| 101 | Ctx: "tengine.tries_upstream_total", |
| 102 | Dims: Dims{ |
| 103 | {ID: "ups_tries", Name: "calls", Algo: collectorapi.Incremental}, |
| 104 | }, |
| 105 | }, |
| 106 | { |
| 107 | ID: "requests_upstream_per_response_code_family_total", |
| 108 | Title: "Upstream Requests Per Response Code Family", |
| 109 | Units: "requests/s", |
| 110 | Fam: "upstream", |
| 111 | Type: collectorapi.Stacked, |
| 112 | Ctx: "tengine.requests_upstream_per_response_code_family_total", |
| 113 | Dims: Dims{ |
| 114 | {ID: "http_ups_4xx", Name: "4xx", Algo: collectorapi.Incremental}, |
| 115 | {ID: "http_ups_5xx", Name: "5xx", Algo: collectorapi.Incremental}, |
| 116 | }, |
| 117 | }, |
| 118 | } |