fix(cups.plugin): add `cups` prefix to chart context (#12444)
Ilya Mashchenko committed
Mar 18, 2022 at 12:00 UTC
3e6d5b4772dba7c1d6ddbeab7518d620917069dd
1 file changed
+8
-8
collectors/cups.plugin/cups_plugin.c
+8
-8
@@ -161,12 +161,12 @@ struct job_metrics *get_job_metrics(char *dest) {
161
reset_job_metrics(&new_job_metrics, NULL);
162
jm = dictionary_set(dict_dest_job_metrics, dest, &new_job_metrics, sizeof(struct job_metrics));
163
164
- printf("CHART cups.job_num_%s '' 'Active job number of destination %s' jobs '%s' job_num stacked %i %i\n", dest, dest, dest, netdata_priority++, netdata_update_every);
164
+ printf("CHART cups.job_num_%s '' 'Active job number of destination %s' jobs '%s' cups.job_num stacked %i %i\n", dest, dest, dest, netdata_priority++, netdata_update_every);
165
printf("DIMENSION pending '' absolute 1 1\n");
166
printf("DIMENSION held '' absolute 1 1\n");
167
printf("DIMENSION processing '' absolute 1 1\n");
168
169
- printf("CHART cups.job_size_%s '' 'Active job size of destination %s' KB '%s' job_size stacked %i %i\n", dest, dest, dest, netdata_priority++, netdata_update_every);
169
+ printf("CHART cups.job_size_%s '' 'Active job size of destination %s' KB '%s' cups.job_size stacked %i %i\n", dest, dest, dest, netdata_priority++, netdata_update_every);
170
printf("DIMENSION pending '' absolute 1 1\n");
171
printf("DIMENSION held '' absolute 1 1\n");
172
printf("DIMENSION processing '' absolute 1 1\n");
@@ -195,12 +195,12 @@ int collect_job_metrics(char *name, void *entry, void *data) {
195
"END\n",
196
name, jm->size_pending, jm->size_held, jm->size_processing);
197
} else {
198
- printf("CHART cups.job_num_%s '' 'Active job number of destination %s' jobs '%s' job_num stacked 1 %i 'obsolete'\n", name, name, name, netdata_update_every);
198
+ printf("CHART cups.job_num_%s '' 'Active job number of destination %s' jobs '%s' cups.job_num stacked 1 %i 'obsolete'\n", name, name, name, netdata_update_every);
199
printf("DIMENSION pending '' absolute 1 1\n");
200
printf("DIMENSION held '' absolute 1 1\n");
201
printf("DIMENSION processing '' absolute 1 1\n");
202
203
- printf("CHART cups.job_size_%s '' 'Active job size of destination %s' KB '%s' job_size stacked 1 %i 'obsolete'\n", name, name, name, netdata_update_every);
203
+ printf("CHART cups.job_size_%s '' 'Active job size of destination %s' KB '%s' cups.job_size stacked 1 %i 'obsolete'\n", name, name, name, netdata_update_every);
204
printf("DIMENSION pending '' absolute 1 1\n");
205
printf("DIMENSION held '' absolute 1 1\n");
206
printf("DIMENSION processing '' absolute 1 1\n");
@@ -375,22 +375,22 @@ int main(int argc, char **argv) {
375
if (unlikely(!cups_printer_by_option_created))
376
{
377
cups_printer_by_option_created = 1;
378
- printf("CHART cups.dest_state '' 'Destinations by state' dests overview dests stacked 100000 %i\n", netdata_update_every);
378
+ printf("CHART cups.dest_state '' 'Destinations by state' dests overview cups.dests_state stacked 100000 %i\n", netdata_update_every);
379
printf("DIMENSION idle '' absolute 1 1\n");
380
printf("DIMENSION printing '' absolute 1 1\n");
381
printf("DIMENSION stopped '' absolute 1 1\n");
382
383
- printf("CHART cups.dest_option '' 'Destinations by option' dests overview dests line 100001 %i\n", netdata_update_every);
383
+ printf("CHART cups.dest_option '' 'Destinations by option' dests overview cups.dests_option line 100001 %i\n", netdata_update_every);
384
printf("DIMENSION total '' absolute 1 1\n");
385
printf("DIMENSION acceptingjobs '' absolute 1 1\n");
386
printf("DIMENSION shared '' absolute 1 1\n");
387
388
- printf("CHART cups.job_num '' 'Total active job number' jobs overview job_num stacked 100002 %i\n", netdata_update_every);
388
+ printf("CHART cups.job_num '' 'Total active job number' jobs overview cups.job_num stacked 100002 %i\n", netdata_update_every);
389
printf("DIMENSION pending '' absolute 1 1\n");
390
printf("DIMENSION held '' absolute 1 1\n");
391
printf("DIMENSION processing '' absolute 1 1\n");
392
393
- printf("CHART cups.job_size '' 'Total active job size' KB overview job_size stacked 100003 %i\n", netdata_update_every);
393
+ printf("CHART cups.job_size '' 'Total active job size' KB overview cups.job_size stacked 100003 %i\n", netdata_update_every);
394
printf("DIMENSION pending '' absolute 1 1\n");
395
printf("DIMENSION held '' absolute 1 1\n");
396
printf("DIMENSION processing '' absolute 1 1\n");