diff options
| author | Pim van den Berg | 2014-05-03 19:17:16 +0200 |
|---|---|---|
| committer | Pim van den Berg | 2014-05-12 21:32:24 +0200 |
| commit | 0a547add2f4cc264380d2dab2c472efe5a1d7094 (patch) | |
| tree | 55bb43a3e31c5814848d61eea92c8438e4a37886 /plugin/processes.json | |
| parent | type/base: set default title to "Plugin Type (PluginInstance) (Category)" (diff) | |
| download | apt-panopticon_cgp-0a547add2f4cc264380d2dab2c472efe5a1d7094.zip apt-panopticon_cgp-0a547add2f4cc264380d2dab2c472efe5a1d7094.tar.gz apt-panopticon_cgp-0a547add2f4cc264380d2dab2c472efe5a1d7094.tar.bz2 apt-panopticon_cgp-0a547add2f4cc264380d2dab2c472efe5a1d7094.tar.xz | |
graph.php: use JSON plugins instead of including PHP plugin files
A couple of big changes here. A lot of logic moved to graph.php.
The PHP plugin files have been rewritten to JSON. In these JSON files
*everything* is optional. Also *NOT* having a JSON plugin file won't
block you from having a graph. The JSON will just make the graphs
prettier (by having a title, y-axis title, legend, colors, etc..).
The Collectd types.db file is parsed and used to determine RRD content.
When things are not defined in the JSON it will fallback to a default.
Diffstat (limited to '')
| -rw-r--r-- | plugin/processes.json | 186 |
1 files changed, 186 insertions, 0 deletions
diff --git a/plugin/processes.json b/plugin/processes.json new file mode 100644 index 0000000..9ffca72 --- /dev/null +++ b/plugin/processes.json | |||
| @@ -0,0 +1,186 @@ | |||
| 1 | { | ||
| 2 | "ps_state": { | ||
| 3 | "title": "Processes", | ||
| 4 | "vertical": "Processes", | ||
| 5 | "type": "stacked", | ||
| 6 | "legend": { | ||
| 7 | "blocked": { | ||
| 8 | "name": "Blocked", | ||
| 9 | "color": "ff00ff" | ||
| 10 | }, | ||
| 11 | "paging": { | ||
| 12 | "name": "Paging", | ||
| 13 | "color": "ffb000" | ||
| 14 | }, | ||
| 15 | "running": { | ||
| 16 | "name": "Running", | ||
| 17 | "color": "00e000" | ||
| 18 | }, | ||
| 19 | "sleeping": { | ||
| 20 | "name": "Sleeping", | ||
| 21 | "color": "0000ff" | ||
| 22 | }, | ||
| 23 | "stopped": { | ||
| 24 | "name": "Stopped", | ||
| 25 | "color": "a000a0" | ||
| 26 | }, | ||
| 27 | "zombies": { | ||
| 28 | "name": "Zombies", | ||
| 29 | "color": "ff0000" | ||
| 30 | } | ||
| 31 | }, | ||
| 32 | "legend_format": "%5.1lf%s" | ||
| 33 | }, | ||
| 34 | "fork_rate": { | ||
| 35 | "title": "Fork rate", | ||
| 36 | "vertical": "forks/s", | ||
| 37 | "type": "stacked", | ||
| 38 | "legend": { | ||
| 39 | "value": { | ||
| 40 | "name": "Forks", | ||
| 41 | "color": "f0a000" | ||
| 42 | } | ||
| 43 | }, | ||
| 44 | "legend_format": "%5.1lf%s" | ||
| 45 | }, | ||
| 46 | "ps_code": { | ||
| 47 | "title": "Text Resident Set ({{PI}})", | ||
| 48 | "vertical": "Bytes", | ||
| 49 | "type": "stacked", | ||
| 50 | "legend": { | ||
| 51 | "value": { | ||
| 52 | "name": "TRS", | ||
| 53 | "color": "0000ff" | ||
| 54 | } | ||
| 55 | }, | ||
| 56 | "legend_format": "%5.1lf%s" | ||
| 57 | }, | ||
| 58 | "ps_count": { | ||
| 59 | "title": "Number of Processes/Threads ({{PI}})", | ||
| 60 | "vertical": "Amount", | ||
| 61 | "type": "stacked", | ||
| 62 | "legend": { | ||
| 63 | "processes": { | ||
| 64 | "name": "Processes", | ||
| 65 | "color": "0000ff" | ||
| 66 | }, | ||
| 67 | "threads": { | ||
| 68 | "name": "Threads", | ||
| 69 | "color": "ff0000" | ||
| 70 | } | ||
| 71 | }, | ||
| 72 | "legend_format": "%5.1lf%s" | ||
| 73 | }, | ||
| 74 | "ps_cputime": { | ||
| 75 | "title": "CPU time ({{PI}})", | ||
| 76 | "vertical": "CPU time [s]", | ||
| 77 | "type": "stacked", | ||
| 78 | "legend": { | ||
| 79 | "user": { | ||
| 80 | "name": "User", | ||
| 81 | "color": "0000ff" | ||
| 82 | }, | ||
| 83 | "syst": { | ||
| 84 | "name": "System", | ||
| 85 | "color": "ff0000" | ||
| 86 | } | ||
| 87 | }, | ||
| 88 | "legend_format": "%5.1lf%s" | ||
| 89 | }, | ||
| 90 | "ps_disk_octets": { | ||
| 91 | "title": "Disk Traffic ({{PI}})", | ||
| 92 | "vertical": "Bytes per second", | ||
| 93 | "type": "io", | ||
| 94 | "legend": { | ||
| 95 | "read": { | ||
| 96 | "name": "Read", | ||
| 97 | "color": "0000ff" | ||
| 98 | }, | ||
| 99 | "write": { | ||
| 100 | "name": "Write", | ||
| 101 | "color": "00b000" | ||
| 102 | } | ||
| 103 | }, | ||
| 104 | "legend_format": "%5.1lf%s" | ||
| 105 | }, | ||
| 106 | "ps_disk_ops": { | ||
| 107 | "title": "Disk Operations ({{PI}})", | ||
| 108 | "vertical": "Ops per second", | ||
| 109 | "type": "io", | ||
| 110 | "legend": { | ||
| 111 | "read": { | ||
| 112 | "name": "Read", | ||
| 113 | "color": "0000ff" | ||
| 114 | }, | ||
| 115 | "write": { | ||
| 116 | "name": "Write", | ||
| 117 | "color": "00b000" | ||
| 118 | } | ||
| 119 | }, | ||
| 120 | "legend_format": "%5.1lf%s" | ||
| 121 | }, | ||
| 122 | "ps_data": { | ||
| 123 | "title": "Data Resident Set ({{PI}})", | ||
| 124 | "vertical": "Bytes", | ||
| 125 | "type": "stacked", | ||
| 126 | "legend": { | ||
| 127 | "value": { | ||
| 128 | "name": "DRS", | ||
| 129 | "color": "0000ff" | ||
| 130 | } | ||
| 131 | }, | ||
| 132 | "legend_format": "%5.1lf%s" | ||
| 133 | }, | ||
| 134 | "ps_pagefaults": { | ||
| 135 | "title": "PageFaults ({{PI}})", | ||
| 136 | "vertical": "Pagefaults", | ||
| 137 | "type": "stacked", | ||
| 138 | "legend": { | ||
| 139 | "minflt": { | ||
| 140 | "name": "Minor", | ||
| 141 | "color": "ff0000" | ||
| 142 | }, | ||
| 143 | "majflt": { | ||
| 144 | "name": "Major", | ||
| 145 | "color": "0000ff" | ||
| 146 | } | ||
| 147 | }, | ||
| 148 | "legend_format": "%5.1lf%s" | ||
| 149 | }, | ||
| 150 | "ps_rss": { | ||
| 151 | "title": "Resident Segment Size ({{PI}})", | ||
| 152 | "vertical": "Bytes", | ||
| 153 | "type": "stacked", | ||
| 154 | "legend": { | ||
| 155 | "value": { | ||
| 156 | "name": "RSS", | ||
| 157 | "color": "0000ff" | ||
| 158 | } | ||
| 159 | }, | ||
| 160 | "legend_format": "%5.1lf%s" | ||
| 161 | }, | ||
| 162 | "ps_stacksize": { | ||
| 163 | "title": "Stacksize ({{PI}})", | ||
| 164 | "vertical": "Bytes", | ||
| 165 | "type": "stacked", | ||
| 166 | "legend": { | ||
| 167 | "value": { | ||
| 168 | "name": "Stacksize", | ||
| 169 | "color": "0000ff" | ||
| 170 | } | ||
| 171 | }, | ||
| 172 | "legend_format": "%5.1lf%s" | ||
| 173 | }, | ||
| 174 | "ps_vm": { | ||
| 175 | "title": "Virtual Memory ({{PI}})", | ||
| 176 | "vertical": "Bytes", | ||
| 177 | "type": "stacked", | ||
| 178 | "legend": { | ||
| 179 | "value": { | ||
| 180 | "name": "Memory", | ||
| 181 | "color": "0000ff" | ||
| 182 | } | ||
| 183 | }, | ||
| 184 | "legend_format": "%5.1lf%s" | ||
| 185 | } | ||
| 186 | } | ||
