mirror of https://github.com/schoebel/mars
net: select server statistics separately
This commit is contained in:
parent
8af110184a
commit
6570a8ea59
|
@ -666,6 +666,9 @@ EXPORT_SYMBOL_GPL(server_brick_type);
|
|||
|
||||
// strategy layer
|
||||
|
||||
int server_show_statist = 0;
|
||||
EXPORT_SYMBOL_GPL(server_show_statist);
|
||||
|
||||
static int _server_thread(void *data)
|
||||
{
|
||||
struct mars_global server_global = {
|
||||
|
@ -699,7 +702,8 @@ static int _server_thread(void *data)
|
|||
|
||||
server_global.global_version++;
|
||||
|
||||
show_statistics(&server_global, "server");
|
||||
if (server_show_statist)
|
||||
show_statistics(&server_global, "server");
|
||||
|
||||
status = mars_kill_brick_when_possible(&server_global, &server_global.brick_anchor, false, (void*)&server_brick_type, false);
|
||||
MARS_DBG("kill server bricks (when possible) = %d\n", status);
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
#include "mars_net.h"
|
||||
#include "lib_limiter.h"
|
||||
|
||||
extern int server_show_statist;
|
||||
|
||||
extern struct mars_limiter server_limiter;
|
||||
|
||||
extern atomic_t server_handler_count;
|
||||
|
|
|
@ -203,7 +203,8 @@ ctl_table mars_table[] = {
|
|||
INT_ENTRY("show_log_messages", brick_say_logging, 0600),
|
||||
#ifdef CONFIG_MARS_DEBUG
|
||||
INT_ENTRY("show_debug_messages", brick_say_debug, 0600),
|
||||
INT_ENTRY("show_statistics", global_show_statist, 0600),
|
||||
INT_ENTRY("show_statistics_global", global_show_statist, 0600),
|
||||
INT_ENTRY("show_statistics_server", server_show_statist, 0600),
|
||||
INT_ENTRY("show_connections", global_show_connections, 0600),
|
||||
#endif
|
||||
INT_ENTRY("logger_completion_semantics", trans_logger_completion_semantics, 0600),
|
||||
|
|
Loading…
Reference in New Issue