@cryptotaxi247 / netdata-1 / commits / 2b4241fe5

add help line to functions response (#14399)

* add help line to functions response * re-arranged columns to make it more usefull and added the new fields for controlling values * renames and re-arrangements

Costa Tsaousis committed Feb 2, 2023 at 18:38 UTC 2b4241fe5aa75d191f92eff6de2ceb339d87cba6
1 file changed +96 -87
collectors/apps.plugin/apps_plugin.c
+96 -87
@@ -10,8 +10,10 @@
10 #include "libnetdata/libnetdata.h"
11 #include "libnetdata/required_dummies.h"
12
13 +#define APPS_PLUGIN_PROCESSES_FUNCTION_DESCRIPTION "Detailed information on the currently running processes."
14 +
15 #define APPS_PLUGIN_FUNCTIONS() do { \
14 - fprintf(stdout, PLUGINSD_KEYWORD_FUNCTION " \"processes\" 10 \"Detailed information on the currently running processes on this node\"\n"); \
16 + fprintf(stdout, PLUGINSD_KEYWORD_FUNCTION " \"processes\" 10 \"%s\"\n", APPS_PLUGIN_PROCESSES_FUNCTION_DESCRIPTION); \
17 } while(0)
18
19
@@ -4286,7 +4288,7 @@ static void apps_plugin_function_processes_help(const char *transaction) {
4288 pluginsd_function_result_end_to_stdout();
4289 }
4290
4289 -#define add_table_field(wb, key, name, visible, type, units, max, sort, sortable, sticky, unique_key, pointer_to, summary, range) do { \
4291 +#define add_table_field(wb, key, name, visible, type, visualization, transform, decimal_points, units, max, sort, sortable, sticky, unique_key, pointer_to, summary, range) do { \
4292 if(fields_added) buffer_strcat(wb, ","); \
4293 buffer_sprintf(wb, "\n \"%s\": {", key); \
4294 buffer_sprintf(wb, "\n \"index\":%d,", fields_added); \
@@ -4296,6 +4298,13 @@ static void apps_plugin_function_processes_help(const char *transaction) {
4298 buffer_sprintf(wb, "\n \"type\":\"%s\",", type); \
4299 if(units) \
4300 buffer_sprintf(wb, "\n \"units\":\"%s\",", (char*)(units)); \
4301 + buffer_sprintf(wb, "\n \"visualization\":\"%s\",", visualization); \
4302 + buffer_sprintf(wb, "\n \"value_options\":{"); \
4303 + if(units) \
4304 + buffer_sprintf(wb, "\n \"units\":\"%s\",", (char*)(units)); \
4305 + buffer_sprintf(wb, "\n \"transform\":\"%s\",", transform); \
4306 + buffer_sprintf(wb, "\n \"decimal_points\":%d", decimal_points); \
4307 + buffer_sprintf(wb, "\n },"); \
4308 if(!isnan((NETDATA_DOUBLE)(max))) \
4309 buffer_sprintf(wb, "\n \"max\":%f,", (NETDATA_DOUBLE)(max)); \
4310 if(pointer_to) \
@@ -4402,10 +4411,12 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4411 "\n \"status\":%d"
4412 ",\n \"type\":\"table\""
4413 ",\n \"update_every\":%d"
4414 + ",\n \"help\":\"%s\""
4415 ",\n \"data\":["
4416 "\n"
4417 , HTTP_RESP_OK
4418 , update_every
4419 + , APPS_PLUGIN_PROCESSES_FUNCTION_DESCRIPTION
4420 );
4421
4422 NETDATA_DOUBLE
@@ -4420,7 +4431,7 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4431 , RSS_max = 0.0
4432 , Shared_max = 0.0
4433 , Swap_max = 0.0
4423 - , MemPcnt_max = 0.0
4434 + , Memory_max = 0.0
4435 ;
4436
4437 unsigned long long
@@ -4529,42 +4540,27 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4540 // gid
4541 buffer_fast_strcat(wb, ",", 1); buffer_print_llu(wb, p->gid);
4542
4532 - // procs
4533 - add_value_field_llu_with_max(wb, Processes, p->children_count);
4534 -
4535 - // threads
4536 - add_value_field_llu_with_max(wb, Threads, p->num_threads);
4537 -
4538 - // uptime
4539 - add_value_field_llu_with_max(wb, Uptime, p->uptime);
4540 -
4541 - // minor page faults
4542 - add_value_field_llu_with_max(wb, MinFlt, p->minflt / RATES_DETAIL);
4543 - add_value_field_llu_with_max(wb, CMinFlt, p->cminflt / RATES_DETAIL);
4544 - add_value_field_llu_with_max(wb, TMinFlt, (p->minflt + p->cminflt) / RATES_DETAIL);
4545 -
4546 - // major page faults
4547 - add_value_field_llu_with_max(wb, MajFlt, p->majflt / RATES_DETAIL);
4548 - add_value_field_llu_with_max(wb, CMajFlt, p->cmajflt / RATES_DETAIL);
4549 - add_value_field_llu_with_max(wb, TMajFlt, (p->majflt + p->cmajflt) / RATES_DETAIL);
4550 -
4543 // CPU utilization %
4544 + add_value_field_ndd_with_max(wb, CPU, (NETDATA_DOUBLE)(p->utime + p->stime + p->gtime + p->cutime + p->cstime + p->cgtime) / cpu_divisor);
4545 add_value_field_ndd_with_max(wb, UserCPU, (NETDATA_DOUBLE)(p->utime) / cpu_divisor);
4546 add_value_field_ndd_with_max(wb, SysCPU, (NETDATA_DOUBLE)(p->stime) / cpu_divisor);
4547 add_value_field_ndd_with_max(wb, GuestCPU, (NETDATA_DOUBLE)(p->gtime) / cpu_divisor);
4548 add_value_field_ndd_with_max(wb, CUserCPU, (NETDATA_DOUBLE)(p->cutime) / cpu_divisor);
4549 add_value_field_ndd_with_max(wb, CSysCPU, (NETDATA_DOUBLE)(p->cstime) / cpu_divisor);
4550 add_value_field_ndd_with_max(wb, CGuestCPU, (NETDATA_DOUBLE)(p->cgtime) / cpu_divisor);
4558 - add_value_field_ndd_with_max(wb, CPU, (NETDATA_DOUBLE)(p->utime + p->stime + p->gtime + p->cutime + p->cstime + p->cgtime) / cpu_divisor);
4551
4552 // memory MiB
4561 - add_value_field_ndd_with_max(wb, VMSize, (NETDATA_DOUBLE)p->status_vmsize / memory_divisor);
4553 + if(MemTotal)
4554 + add_value_field_ndd_with_max(wb, Memory, (NETDATA_DOUBLE)p->status_vmrss * 100.0 / (NETDATA_DOUBLE)MemTotal);
4555 +
4556 add_value_field_ndd_with_max(wb, RSS, (NETDATA_DOUBLE)p->status_vmrss / memory_divisor);
4557 add_value_field_ndd_with_max(wb, Shared, (NETDATA_DOUBLE)p->status_vmshared / memory_divisor);
4558 + add_value_field_ndd_with_max(wb, VMSize, (NETDATA_DOUBLE)p->status_vmsize / memory_divisor);
4559 add_value_field_ndd_with_max(wb, Swap, (NETDATA_DOUBLE)p->status_vmswap / memory_divisor);
4560
4566 - if(MemTotal)
4567 - add_value_field_ndd_with_max(wb, MemPcnt, (NETDATA_DOUBLE)p->status_vmrss * 100.0 / (NETDATA_DOUBLE)MemTotal);
4561 + // Physical I/O
4562 + add_value_field_llu_with_max(wb, PReads, p->io_storage_bytes_read / io_divisor);
4563 + add_value_field_llu_with_max(wb, PWrites, p->io_storage_bytes_written / io_divisor);
4564
4565 // Logical I/O
4566 #ifndef __FreeBSD__
@@ -4572,15 +4568,22 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4568 add_value_field_llu_with_max(wb, LWrites, p->io_logical_bytes_written / io_divisor);
4569 #endif
4570
4575 - // Physical I/O
4576 - add_value_field_llu_with_max(wb, PReads, p->io_storage_bytes_read / io_divisor);
4577 - add_value_field_llu_with_max(wb, PWrites, p->io_storage_bytes_written / io_divisor);
4578 -
4571 // I/O calls
4572 add_value_field_llu_with_max(wb, RCalls, p->io_read_calls / RATES_DETAIL);
4573 add_value_field_llu_with_max(wb, WCalls, p->io_write_calls / RATES_DETAIL);
4574
4575 + // minor page faults
4576 + add_value_field_llu_with_max(wb, MinFlt, p->minflt / RATES_DETAIL);
4577 + add_value_field_llu_with_max(wb, CMinFlt, p->cminflt / RATES_DETAIL);
4578 + add_value_field_llu_with_max(wb, TMinFlt, (p->minflt + p->cminflt) / RATES_DETAIL);
4579 +
4580 + // major page faults
4581 + add_value_field_llu_with_max(wb, MajFlt, p->majflt / RATES_DETAIL);
4582 + add_value_field_llu_with_max(wb, CMajFlt, p->cmajflt / RATES_DETAIL);
4583 + add_value_field_llu_with_max(wb, TMajFlt, (p->majflt + p->cmajflt) / RATES_DETAIL);
4584 +
4585 // open file descriptors
4586 + add_value_field_llu_with_max(wb, FDs, p->openfds.files + p->openfds.pipes + p->openfds.sockets + p->openfds.inotifies + p->openfds.eventfds + p->openfds.timerfds + p->openfds.signalfds + p->openfds.eventpolls + p->openfds.other);
4587 add_value_field_llu_with_max(wb, Files, p->openfds.files);
4588 add_value_field_llu_with_max(wb, Pipes, p->openfds.pipes);
4589 add_value_field_llu_with_max(wb, Sockets, p->openfds.sockets);
@@ -4590,7 +4593,11 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4593 add_value_field_llu_with_max(wb, SigFDs, p->openfds.signalfds);
4594 add_value_field_llu_with_max(wb, EvPollFDs, p->openfds.eventpolls);
4595 add_value_field_llu_with_max(wb, OtherFDs, p->openfds.other);
4593 - add_value_field_llu_with_max(wb, FDs, p->openfds.files + p->openfds.pipes + p->openfds.sockets + p->openfds.inotifies + p->openfds.eventfds + p->openfds.timerfds + p->openfds.signalfds + p->openfds.eventpolls + p->openfds.other);
4596 +
4597 + // processes, threads, uptime
4598 + add_value_field_llu_with_max(wb, Processes, p->children_count);
4599 + add_value_field_llu_with_max(wb, Threads, p->num_threads);
4600 + add_value_field_llu_with_max(wb, Uptime, p->uptime);
4601
4602 buffer_fast_strcat(wb, "]", 1);
4603
@@ -4606,75 +4613,77 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4613
4614 // IMPORTANT!
4615 // THE ORDER SHOULD BE THE SAME WITH THE VALUES!
4609 - add_table_field(wb, "PID", "Process ID", true, "integer", NULL, NAN, "ascending", true, true, true, NULL, "count_unique", false);
4610 - add_table_field(wb, "Cmd", "Process Name", true, "string", NULL, NAN, "ascending", true, true, false, NULL, "count_unique", false);
4616 + add_table_field(wb, "PID", "Process ID", true, "integer", "value", "number", 0, NULL, NAN, "ascending", true, true, true, NULL, "count_unique", false);
4617 + add_table_field(wb, "Cmd", "Process Name", true, "string", "value", "none", 0, NULL, NAN, "ascending", true, true, false, NULL, "count_unique", false);
4618
4619 #ifdef NETDATA_DEV_MODE
4613 - add_table_field(wb, "CmdLine", "Command Line", false, "detail-string:Cmd", NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4620 + add_table_field(wb, "CmdLine", "Command Line", false, "detail-string:Cmd", "value", "none", 0, NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4621 #endif
4615 - add_table_field(wb, "PPID", "Parent Process ID", false, "integer", NULL, NAN, "ascending", true, false, false, "PID", "count_unique", false);
4616 - add_table_field(wb, "Category", "Category (apps_groups.conf)", true, "string", NULL, NAN, "ascending", true, true, false, NULL, "count_unique", false);
4617 - add_table_field(wb, "User", "User Owner", true, "string", NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4618 - add_table_field(wb, "Uid", "User ID", false, "integer", NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4619 - add_table_field(wb, "Group", "Group Owner", false, "string", NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4620 - add_table_field(wb, "Gid", "Group ID", false, "integer", NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4621 - add_table_field(wb, "Processes", "Processes", true, "bar-with-integer", "processes", Processes_max, "descending", true, false, false, NULL, "sum", true);
4622 - add_table_field(wb, "Threads", "Threads", true, "bar-with-integer", "threads", Threads_max, "descending", true, false, false, NULL, "sum", true);
4623 - add_table_field(wb, "Uptime", "Uptime in seconds", true, "duration", "seconds", Uptime_max, "descending", true, false, false, NULL, "max", true);
4624 -
4625 - // minor page faults
4626 - add_table_field(wb, "MinFlt", "Minor Page Faults/s", false, "bar", "pgflts/s", MinFlt_max, "descending", true, false, false, NULL, "sum", true);
4627 - add_table_field(wb, "CMinFlt", "Children Minor Page Faults/s", false, "bar", "pgflts/s", CMinFlt_max, "descending", true, false, false, NULL, "sum", true);
4628 - add_table_field(wb, "TMinFlt", "Total Minor Page Faults/s", false, "bar", "pgflts/s", TMinFlt_max, "descending", true, false, false, NULL, "sum", true);
4629 -
4630 - // major page faults
4631 - add_table_field(wb, "MajFlt", "Major Page Faults/s", false, "bar", "pgflts/s", MajFlt_max, "descending", true, false, false, NULL, "sum", true);
4632 - add_table_field(wb, "CMajFlt", "Children Major Page Faults/s", false, "bar", "pgflts/s", CMajFlt_max, "descending", true, false, false, NULL, "sum", true);
4633 - add_table_field(wb, "TMajFlt", "Total Major Page Faults/s", true, "bar", "pgflts/s", TMajFlt_max, "descending", true, false, false, NULL, "sum", true);
4622 + add_table_field(wb, "PPID", "Parent Process ID", false, "integer", "value", "number", 0, NULL, NAN, "ascending", true, false, false, "PID", "count_unique", false);
4623 + add_table_field(wb, "Category", "Category (apps_groups.conf)", true, "string", "value", "none", 0, NULL, NAN, "ascending", true, true, false, NULL, "count_unique", false);
4624 + add_table_field(wb, "User", "User Owner", true, "string", "value", "none", 0, NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4625 + add_table_field(wb, "Uid", "User ID", false, "integer", "value", "number", 0, NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4626 + add_table_field(wb, "Group", "Group Owner", false, "string", "value", "none", 0, NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4627 + add_table_field(wb, "Gid", "Group ID", false, "integer", "value", "number", 0, NULL, NAN, "ascending", true, false, false, NULL, "count_unique", false);
4628
4629 // CPU utilization
4636 - add_table_field(wb, "UserCPU", "User CPU time", false, "bar", "%", UserCPU_max, "descending", true, false, false, NULL, "sum", true);
4637 - add_table_field(wb, "SysCPU", "System CPU Time", false, "bar", "%", SysCPU_max, "descending", true, false, false, NULL, "sum", true);
4638 - add_table_field(wb, "GuestCPU", "Guest CPU Time", false, "bar", "%", GuestCPU_max, "descending", true, false, false, NULL, "sum", true);
4639 - add_table_field(wb, "CUserCPU", "Children User CPU Time", false, "bar", "%", CUserCPU_max, "descending", true, false, false, NULL, "sum", true);
4640 - add_table_field(wb, "CSysCPU", "Children System CPU Time", false, "bar", "%", CSysCPU_max, "descending", true, false, false, NULL, "sum", true);
4641 - add_table_field(wb, "CGuestCPU", "Children Guest CPU Time", false, "bar", "%", CGuestCPU_max, "descending", true, false, false, NULL, "sum", true);
4642 - add_table_field(wb, "CPU", "Total CPU Time", true, "bar", "%", CPU_max, "descending", true, false, false, NULL, "sum", true);
4630 + add_table_field(wb, "CPU", "Total CPU Time (100% = 1 core)", true, "bar-with-integer", "bar", "number", 2, "%", CPU_max, "descending", true, false, false, NULL, "sum", true);
4631 + add_table_field(wb, "UserCPU", "User CPU time (100% = 1 core)", false, "bar-with-integer", "bar", "number", 2, "%", UserCPU_max, "descending", true, false, false, NULL, "sum", true);
4632 + add_table_field(wb, "SysCPU", "System CPU Time (100% = 1 core)", false, "bar-with-integer", "bar", "number", 2, "%", SysCPU_max, "descending", true, false, false, NULL, "sum", true);
4633 + add_table_field(wb, "GuestCPU", "Guest CPU Time (100% = 1 core)", false, "bar-with-integer", "bar", "number", 2, "%", GuestCPU_max, "descending", true, false, false, NULL, "sum", true);
4634 + add_table_field(wb, "CUserCPU", "Children User CPU Time (100% = 1 core)", false, "bar-with-integer", "bar", "number", 2, "%", CUserCPU_max, "descending", true, false, false, NULL, "sum", true);
4635 + add_table_field(wb, "CSysCPU", "Children System CPU Time (100% = 1 core)", false, "bar-with-integer", "bar", "number", 2, "%", CSysCPU_max, "descending", true, false, false, NULL, "sum", true);
4636 + add_table_field(wb, "CGuestCPU", "Children Guest CPU Time (100% = 1 core)", false, "bar-with-integer", "bar", "number", 2, "%", CGuestCPU_max, "descending", true, false, false, NULL, "sum", true);
4637
4638 // memory
4645 - add_table_field(wb, "VMSize", "Virtual Memory Size", false, "bar", "MiB", VMSize_max, "descending", true, false, false, NULL, "sum", true);
4646 - add_table_field(wb, "RSS", "Resident Set Size", MemTotal ? false : true, "bar", "MiB", RSS_max, "descending", true, false, false, NULL, "sum", true);
4647 - add_table_field(wb, "Shared", "Shared Pages", false, "bar", "MiB", Shared_max, "descending", true, false, false, NULL, "sum", true);
4648 - add_table_field(wb, "Swap", "Swap Memory", false, "bar", "MiB", Swap_max, "descending", true, false, false, NULL, "sum", true);
4649 -
4639 if(MemTotal)
4651 - add_table_field(wb, "MemPcnt", "Memory Percentage", true, "bar", "%", 100.0, "descending", true, false, false, NULL, "sum", true);
4640 + add_table_field(wb, "Memory", "Memory Percentage", true, "bar-with-integer", "bar", "number", 2, "%", 100.0, "descending", true, false, false, NULL, "sum", true);
4641
4653 - // Logical I/O
4654 -#ifndef __FreeBSD__
4655 - add_table_field(wb, "LReads", "Logical I/O Reads", false, "bar", "KiB/s", LReads_max, "descending", true, false, false, NULL, "sum", true);
4656 - add_table_field(wb, "LWrites", "Logical I/O Writes", false, "bar", "KiB/s", LWrites_max, "descending", true, false, false, NULL, "sum", true);
4657 -#endif
4642 + add_table_field(wb, "Resident", "Resident Set Size", true, "bar-with-integer", "bar", "number", 2, "MiB", RSS_max, "descending", true, false, false, NULL, "sum", true);
4643 + add_table_field(wb, "Shared", "Shared Pages", true, "bar-with-integer", "bar", "number", 2, "MiB", Shared_max, "descending", true, false, false, NULL, "sum", true);
4644 + add_table_field(wb, "Virtual", "Virtual Memory Size", true, "bar-with-integer", "bar", "number", 2, "MiB", VMSize_max, "descending", true, false, false, NULL, "sum", true);
4645 + add_table_field(wb, "Swap", "Swap Memory", false, "bar-with-integer", "bar", "number", 2, "MiB", Swap_max, "descending", true, false, false, NULL, "sum", true);
4646
4647 // Physical I/O
4660 - add_table_field(wb, "PReads", "Physical I/O Reads", true, "bar", "KiB/s", PReads_max, "descending", true, false, false, NULL, "sum", true);
4661 - add_table_field(wb, "PWrites", "Physical I/O Writes", true, "bar", "KiB/s", PWrites_max, "descending", true, false, false, NULL, "sum", true);
4648 + add_table_field(wb, "PReads", "Physical I/O Reads", true, "bar-with-integer", "bar", "number", 2, "KiB/s", PReads_max, "descending", true, false, false, NULL, "sum", true);
4649 + add_table_field(wb, "PWrites", "Physical I/O Writes", true, "bar-with-integer", "bar", "number", 2, "KiB/s", PWrites_max, "descending", true, false, false, NULL, "sum", true);
4650 +
4651 + // Logical I/O
4652 +#ifndef __FreeBSD__
4653 + add_table_field(wb, "LReads", "Logical I/O Reads", true, "bar-with-integer", "bar", "number", 2, "KiB/s", LReads_max, "descending", true, false, false, NULL, "sum", true);
4654 + add_table_field(wb, "LWrites", "Logical I/O Writes", true, "bar-with-integer", "bar", "number", 2, "KiB/s", LWrites_max, "descending", true, false, false, NULL, "sum", true);
4655 +#endif
4656
4657 // I/O calls
4664 - add_table_field(wb, "RCalls", "I/O Read Calls", false, "bar", "calls/s", RCalls_max, "descending", true, false, false, NULL, "sum", true);
4665 - add_table_field(wb, "WCalls", "I/O Write Calls", false, "bar", "calls/s", WCalls_max, "descending", true, false, false, NULL, "sum", true);
4658 + add_table_field(wb, "RCalls", "I/O Read Calls", true, "bar-with-integer", "bar", "number", 2, "calls/s", RCalls_max, "descending", true, false, false, NULL, "sum", true);
4659 + add_table_field(wb, "WCalls", "I/O Write Calls", true, "bar-with-integer", "bar", "number", 2, "calls/s", WCalls_max, "descending", true, false, false, NULL, "sum", true);
4660 +
4661 + // minor page faults
4662 + add_table_field(wb, "MinFlt", "Minor Page Faults/s", false, "bar-with-integer", "bar", "number", 2, "pgflts/s", MinFlt_max, "descending", true, false, false, NULL, "sum", true);
4663 + add_table_field(wb, "CMinFlt", "Children Minor Page Faults/s", false, "bar-with-integer", "bar", "number", 2, "pgflts/s", CMinFlt_max, "descending", true, false, false, NULL, "sum", true);
4664 + add_table_field(wb, "TMinFlt", "Total Minor Page Faults/s", false, "bar-with-integer", "bar", "number", 2, "pgflts/s", TMinFlt_max, "descending", true, false, false, NULL, "sum", true);
4665 +
4666 + // major page faults
4667 + add_table_field(wb, "MajFlt", "Major Page Faults/s", false, "bar-with-integer", "bar", "number", 2, "pgflts/s", MajFlt_max, "descending", true, false, false, NULL, "sum", true);
4668 + add_table_field(wb, "CMajFlt", "Children Major Page Faults/s", false, "bar-with-integer", "bar", "number", 2, "pgflts/s", CMajFlt_max, "descending", true, false, false, NULL, "sum", true);
4669 + add_table_field(wb, "TMajFlt", "Total Major Page Faults/s", true, "bar-with-integer", "bar", "number", 2, "pgflts/s", TMajFlt_max, "descending", true, false, false, NULL, "sum", true);
4670
4671 // open file descriptors
4668 - add_table_field(wb, "Files", "Open Files", false, "bar", "fds", Files_max, "descending", true, false, false, NULL, "sum", true);
4669 - add_table_field(wb, "Pipes", "Open Pipes", false, "bar", "fds", Pipes_max, "descending", true, false, false, NULL, "sum", true);
4670 - add_table_field(wb, "Sockets", "Open Sockets", false, "bar", "fds", Sockets_max, "descending", true, false, false, NULL, "sum", true);
4671 - add_table_field(wb, "iNotiFDs", "Open iNotify Descriptors", false, "bar", "fds", iNotiFDs_max, "descending", true, false, false, NULL, "sum", true);
4672 - add_table_field(wb, "EventFDs", "Open Event Descriptors", false, "bar", "fds", EventFDs_max, "descending", true, false, false, NULL, "sum", true);
4673 - add_table_field(wb, "TimerFDs", "Open Timer Descriptors", false, "bar", "fds", TimerFDs_max, "descending", true, false, false, NULL, "sum", true);
4674 - add_table_field(wb, "SigFDs", "Open Signal Descriptors", false, "bar", "fds", SigFDs_max, "descending", true, false, false, NULL, "sum", true);
4675 - add_table_field(wb, "EvPollFDs", "Open Event Poll Descriptors", false, "bar", "fds", EvPollFDs_max, "descending", true, false, false, NULL, "sum", true);
4676 - add_table_field(wb, "OtherFDs", "Other Open Descriptors", false, "bar", "fds", OtherFDs_max, "descending", true, false, false, NULL, "sum", true);
4677 - add_table_field(wb, "FDs", "All Open File Descriptors", true, "bar", "fds", FDs_max, "descending", true, false, false, NULL, "sum", true);
4672 + add_table_field(wb, "FDs", "All Open File Descriptors", true, "bar-with-integer", "bar", "number", 0, "fds", FDs_max, "descending", true, false, false, NULL, "sum", true);
4673 + add_table_field(wb, "Files", "Open Files", true, "bar-with-integer", "bar", "number", 0, "fds", Files_max, "descending", true, false, false, NULL, "sum", true);
4674 + add_table_field(wb, "Pipes", "Open Pipes", true, "bar-with-integer", "bar", "number", 0, "fds", Pipes_max, "descending", true, false, false, NULL, "sum", true);
4675 + add_table_field(wb, "Sockets", "Open Sockets", true, "bar-with-integer", "bar", "number", 0, "fds", Sockets_max, "descending", true, false, false, NULL, "sum", true);
4676 + add_table_field(wb, "iNotiFDs", "Open iNotify Descriptors", false, "bar-with-integer", "bar", "number", 0, "fds", iNotiFDs_max, "descending", true, false, false, NULL, "sum", true);
4677 + add_table_field(wb, "EventFDs", "Open Event Descriptors", false, "bar-with-integer", "bar", "number", 0, "fds", EventFDs_max, "descending", true, false, false, NULL, "sum", true);
4678 + add_table_field(wb, "TimerFDs", "Open Timer Descriptors", false, "bar-with-integer", "bar", "number", 0, "fds", TimerFDs_max, "descending", true, false, false, NULL, "sum", true);
4679 + add_table_field(wb, "SigFDs", "Open Signal Descriptors", false, "bar-with-integer", "bar", "number", 0, "fds", SigFDs_max, "descending", true, false, false, NULL, "sum", true);
4680 + add_table_field(wb, "EvPollFDs", "Open Event Poll Descriptors", false, "bar-with-integer", "bar", "number", 0, "fds", EvPollFDs_max, "descending", true, false, false, NULL, "sum", true);
4681 + add_table_field(wb, "OtherFDs", "Other Open Descriptors", false, "bar-with-integer", "bar", "number", 0, "fds", OtherFDs_max, "descending", true, false, false, NULL, "sum", true);
4682 +
4683 + // processes, threads, uptime
4684 + add_table_field(wb, "Processes", "Processes", true, "bar-with-integer", "bar", "number", 0, "processes", Processes_max, "descending", true, false, false, NULL, "sum", true);
4685 + add_table_field(wb, "Threads", "Threads", true, "bar-with-integer", "bar", "number", 0, "threads", Threads_max, "descending", true, false, false, NULL, "sum", true);
4686 + add_table_field(wb, "Uptime", "Uptime in seconds", true, "duration", "bar", "duration", 2, "seconds", Uptime_max, "descending", true, false, false, NULL, "max", true);
4687
4688 buffer_strcat(
4689 wb,
@@ -4690,7 +4699,7 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4699 "\n \"Memory\": {"
4700 "\n \"name\":\"Memory\","
4701 "\n \"type\":\"stacked-bar\","
4693 - "\n \"columns\": [ \"VMSize\", \"RSS\", \"Shared\", \"Swap\" ]"
4702 + "\n \"columns\": [ \"Virtual\", \"Resident\", \"Shared\", \"Swap\" ]"
4703 "\n },"
4704 );
4705
@@ -4701,7 +4710,7 @@ static void apps_plugin_function_processes(const char *transaction, char *functi
4710 "\n \"MemoryPercent\": {"
4711 "\n \"name\":\"Memory Percentage\","
4712 "\n \"type\":\"stacked-bar\","
4704 - "\n \"columns\": [ \"MemPcnt\" ]"
4713 + "\n \"columns\": [ \"Memory\" ]"
4714 "\n },"
4715 );
4716