Motr  M0
Test Console user-space program
Collaboration diagram for Test Console user-space program:

Macros

#define DESCRIBE(field, name, description)
 

Functions

 DESCRIBE (addr_console4servers, 'A', "Console command endpoint address " "for the test servers")
 
 DESCRIBE (addr_console4clients, 'a', "Console command endpoint address " "for the test clients")
 
 DESCRIBE (servers, 'C', "List of test server command endpoints")
 
 DESCRIBE (clients, 'c', "List of test client command endpoints")
 
 DESCRIBE (data_servers, 'D', "List of test server data endpoints")
 
 DESCRIBE (data_clients, 'd', "List of test client data endpoints")
 
 DESCRIBE (test_type, 't', "Test type, 'ping' or 'bulk'")
 
 DESCRIBE (msg_nr, 'n', "Number of test messages for the " "test client (for each server)")
 
 DESCRIBE (msg_size, 's', "Test message size")
 
 DESCRIBE (test_time_limit, 'T', "Test run time limit, seconds")
 
 DESCRIBE (bd_buf_nr_server, 'B', "Number of message buffers for bulk buffer " "network descriptors for the test server")
 
 DESCRIBE (bd_buf_nr_client, 'b', "Number of message buffers for bulk buffer " "network descriptors for the test client")
 
 DESCRIBE (bd_buf_size, 'f', "Size of buffer for bulk buffer " "network descriptors")
 
 DESCRIBE (bd_nr_max, 'g', "Maximum number of bulk buffer " "network descriptors in msg buffer")
 
 DESCRIBE (concurrency_server, 'E', "Test server concurrency")
 
 DESCRIBE (concurrency_client, 'e', "Test client concurrency")
 
static bool addr_check (const char *addr)
 
static bool addr_list_check (struct m0_net_test_slist *slist)
 
static bool config_check (struct m0_net_test_console_cfg *cfg)
 
static void print_slist (char *name, struct m0_net_test_slist *slist)
 
static void config_print (struct m0_net_test_console_cfg *cfg)
 
static int configure (int argc, char *argv[], struct m0_net_test_console_cfg *cfg)
 
static void config_free (struct m0_net_test_console_cfg *cfg)
 
static bool console_step (struct m0_net_test_console_ctx *ctx, enum m0_net_test_role role, enum m0_net_test_cmd_type cmd_type, const char *text_pre, const char *text_post)
 
static void print_msg_nr (const char *descr, struct m0_net_test_msg_nr *msg_nr)
 
static void print_stats (const char *descr, struct m0_net_test_stats *stats)
 
static void bsize_print (const char *descr, struct m0_net_test_console_ctx *ctx, double msg_nr)
 
static double avg_total (m0_time_t diff_t, double msg_nr)
 
static void print_status_data (struct m0_net_test_console_ctx *ctx)
 
static void print_msg_nr_parsable (const char *prefix, struct m0_net_test_msg_nr *msg_nr)
 
static void print_stats_parsable (const char *prefix, struct m0_net_test_stats *stats)
 
static void print_status_data_implementation (struct m0_net_test_cmd_status_data *sd, bool parsable)
 
static void print_status_data_v (struct m0_net_test_cmd_status_data *sd)
 
static void print_status_data_parsable (const char *prefix, struct m0_net_test_cmd_status_data *sd)
 
static int console_run (struct m0_net_test_console_ctx *ctx)
 
int main (int argc, char *argv[])
 

Variables

static bool produce_parsable_output = true
 
static bool parse_trace_buffer = false
 

Detailed Description

See also
Motr Network Benchmark

Macro Definition Documentation

◆ DESCRIBE

#define DESCRIBE (   field,
  name,
  description 
)
Value:
static const char *msg_##field = description; \
static const char opt_##field = name
const char * name
Definition: trace.c:110
static int field(struct ff2c_context *ctx, struct ff2c_term *term)
Definition: parser.c:84
description
Definition: setup.py:30

Definition at line 108 of file console_u.c.

Function Documentation

◆ addr_check()

static bool addr_check ( const char *  addr)
static
Todo:
additional checks

Definition at line 149 of file console_u.c.

Here is the caller graph for this function:

◆ addr_list_check()

static bool addr_list_check ( struct m0_net_test_slist slist)
static

Definition at line 159 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ avg_total()

static double avg_total ( m0_time_t  diff_t,
double  msg_nr 
)
static

Definition at line 385 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ bsize_print()

static void bsize_print ( const char *  descr,
struct m0_net_test_console_ctx ctx,
double  msg_nr 
)
static

Definition at line 377 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ config_check()

static bool config_check ( struct m0_net_test_console_cfg cfg)
static

Definition at line 173 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ config_free()

static void config_free ( struct m0_net_test_console_cfg cfg)
static

Definition at line 335 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ config_print()

static void config_print ( struct m0_net_test_console_cfg cfg)
static
Todo:
write text

Definition at line 216 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ configure()

static int configure ( int  argc,
char *  argv[],
struct m0_net_test_console_cfg cfg 
)
static

Definition at line 249 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ console_run()

static int console_run ( struct m0_net_test_console_ctx ctx)
static
Todo:
make command line parameter
Todo:
can be interrupted

Definition at line 535 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ console_step()

static bool console_step ( struct m0_net_test_console_ctx ctx,
enum m0_net_test_role  role,
enum m0_net_test_cmd_type  cmd_type,
const char *  text_pre,
const char *  text_post 
)
static

Definition at line 345 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ DESCRIBE() [1/16]

DESCRIBE ( addr_console4servers  ,
'A ,
"Console command endpoint address " "for the test servers  
)

◆ DESCRIBE() [2/16]

DESCRIBE ( addr_console4clients  ,
'a'  ,
"Console command endpoint address " "for the test clients  
)

◆ DESCRIBE() [3/16]

DESCRIBE ( servers  ,
'C ,
"List of test server command endpoints"   
)

◆ DESCRIBE() [4/16]

DESCRIBE ( clients  ,
'c ,
"List of test client command endpoints"   
)

◆ DESCRIBE() [5/16]

DESCRIBE ( data_servers  ,
'D ,
"List of test server data endpoints"   
)

◆ DESCRIBE() [6/16]

DESCRIBE ( data_clients  ,
'd'  ,
"List of test client data endpoints"   
)

◆ DESCRIBE() [7/16]

DESCRIBE ( test_type  ,
't ,
"Test  type,
'ping' or 'bulk'"   
)

◆ DESCRIBE() [8/16]

DESCRIBE ( msg_nr  ,
'n ,
"Number of test messages for the " "test client (for each server)"   
)

◆ DESCRIBE() [9/16]

DESCRIBE ( msg_size  ,
's ,
"Test message size  
)

◆ DESCRIBE() [10/16]

DESCRIBE ( test_time_limit  ,
'T ,
"Test run time  limit,
seconds"   
)

◆ DESCRIBE() [11/16]

DESCRIBE ( bd_buf_nr_server  ,
'B ,
"Number of message buffers for bulk buffer " "network descriptors for the test server"   
)

◆ DESCRIBE() [12/16]

DESCRIBE ( bd_buf_nr_client  ,
'b'  ,
"Number of message buffers for bulk buffer " "network descriptors for the test client  
)

◆ DESCRIBE() [13/16]

DESCRIBE ( bd_buf_size  ,
'f ,
"Size of buffer for bulk buffer " "network descriptors"   
)

◆ DESCRIBE() [14/16]

DESCRIBE ( bd_nr_max  ,
'g ,
"Maximum number of bulk buffer " "network descriptors in msg buffer  
)

◆ DESCRIBE() [15/16]

DESCRIBE ( concurrency_server  ,
'E ,
"Test server concurrency"   
)

◆ DESCRIBE() [16/16]

DESCRIBE ( concurrency_client  ,
'e'  ,
"Test client concurrency"   
)

◆ main()

int main ( int  argc,
char *  argv[] 
)
Todo:
add to command line parameters
Todo:
where is the error

Definition at line 624 of file console_u.c.

Here is the call graph for this function:

◆ print_msg_nr()

static void print_msg_nr ( const char *  descr,
struct m0_net_test_msg_nr msg_nr 
)
static

Definition at line 362 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_msg_nr_parsable()

static void print_msg_nr_parsable ( const char *  prefix,
struct m0_net_test_msg_nr msg_nr 
)
static

Definition at line 435 of file console_u.c.

Here is the caller graph for this function:

◆ print_slist()

static void print_slist ( char *  name,
struct m0_net_test_slist slist 
)
static

Definition at line 205 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_stats()

static void print_stats ( const char *  descr,
struct m0_net_test_stats stats 
)
static

Definition at line 368 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_stats_parsable()

static void print_stats_parsable ( const char *  prefix,
struct m0_net_test_stats stats 
)
static

Definition at line 446 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_status_data()

static void print_status_data ( struct m0_net_test_console_ctx ctx)
static

Definition at line 393 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_status_data_implementation()

static void print_status_data_implementation ( struct m0_net_test_cmd_status_data sd,
bool  parsable 
)
static

Definition at line 460 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_status_data_parsable()

static void print_status_data_parsable ( const char *  prefix,
struct m0_net_test_cmd_status_data sd 
)
static

Definition at line 526 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_status_data_v()

static void print_status_data_v ( struct m0_net_test_cmd_status_data sd)
static

Definition at line 521 of file console_u.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ parse_trace_buffer

bool parse_trace_buffer = false
static

Parse trace buffer (from stdin to stdout).

Definition at line 147 of file console_u.c.

◆ produce_parsable_output

bool produce_parsable_output = true
static

Print string with test results in parsable format in the end of the console output.

Definition at line 142 of file console_u.c.