CUBRID Engine
latest
|
#include <stdio.h>
#include <errno.h>
#include <string.h>
#include <stdlib.h>
#include "cas_common.h"
#include "broker_log_top.h"
#include "log_top_string.h"
#include "broker_log_util.h"
Go to the source code of this file.
Classes | |
struct | t_log_info |
Macros | |
#define | TRAN_LOG_MAX_COUNT 1000 |
#define | LOG_TOP_RES_FILE_TRAN "log_top.t" |
Typedefs | |
typedef struct t_log_info | T_LOG_INFO |
Functions | |
static int | log_top (FILE *fp, char *filename, long start_offset, long end_offset) |
static int | info_delete (T_LOG_INFO *info) |
static void | print_result (void) |
static int | info_add (T_LOG_INFO *info, char *start_date, char *end_date) |
int | log_top_tran (int argc, char *argv[], int arg_start) |
Variables | |
static int | info_arr_size = 0 |
static int | info_arr_max_size = TRAN_LOG_MAX_COUNT |
static T_LOG_INFO | info_arr [TRAN_LOG_MAX_COUNT+1] |
#define LOG_TOP_RES_FILE_TRAN "log_top.t" |
Definition at line 37 of file broker_log_top_tran.c.
Referenced by print_result().
#define TRAN_LOG_MAX_COUNT 1000 |
Definition at line 36 of file broker_log_top_tran.c.
Referenced by print_result().
typedef struct t_log_info T_LOG_INFO |
Definition at line 39 of file broker_log_top_tran.c.
|
static |
Definition at line 248 of file broker_log_top_tran.c.
References check_log_time(), FREE_MEM, i, info_arr_max_size, info_arr_size, info_delete(), t_log_info::logstr, and t_log_info::runtime.
Referenced by log_top().
|
static |
Definition at line 278 of file broker_log_top_tran.c.
References info_arr_size, and t_log_info::runtime.
Referenced by info_add(), and print_result().
|
static |
Definition at line 100 of file broker_log_top_tran.c.
References CAS_LOG_BEGIN_WITH_MONTH, CAS_LOG_BEGIN_WITH_YEAR, DATE_STR_LEN, error(), GET_CUR_DATE_STR, get_msg_start_ptr(), info_add(), is_cas_log(), t_log_info::logstr, LT_INVAILD_VERSION, LT_NO_ERROR, LT_OTHER_ERROR, NULL, t_log_info::runtime, strdup(), strlen, t_string_add(), t_string_clear(), t_string_free(), t_string_make(), t_string_str(), and ut_get_line().
Referenced by log_top_tran().
int log_top_tran | ( | int | argc, |
char * | argv[], | ||
int | arg_start | ||
) |
Definition at line 56 of file broker_log_top_tran.c.
References argc, error(), get_file_offset(), i, info_arr_size, log_top(), LT_INVAILD_VERSION, NULL, and print_result().
Referenced by main().
|
static |
Definition at line 216 of file broker_log_top_tran.c.
References FREE_MEM, i, info_delete(), LOG_TOP_RES_FILE_TRAN, t_log_info::logstr, NULL, and TRAN_LOG_MAX_COUNT.
Referenced by log_top_tran().
|
static |
Definition at line 53 of file broker_log_top_tran.c.
|
static |
Definition at line 52 of file broker_log_top_tran.c.
Referenced by info_add().
|
static |
Definition at line 51 of file broker_log_top_tran.c.
Referenced by info_add(), info_delete(), and log_top_tran().