entity_addr_t g_my_addr;
-md_config_t g_debug_after_conf;
md_config_t g_conf;
#include <stdlib.h>
OPTION(debug, debug_mon, 0, INT, 1),
OPTION(debug, debug_paxos, 0, INT, 0),
OPTION(debug, debug_tp, 0, INT, 0),
- OPTION(debug, debug_after, 0, INT, 0),
OPTION(clock, clock_lock, 0, BOOL, false),
OPTION(clock, clock_tare, 0, BOOL, false),
OPTION(global, ms_tcp_nodelay, 0, BOOL, true),
}
};
-class C_Debug : public Context {
- public:
- void finish(int) {
- int size = &g_conf.debug_after - &g_conf.debug;
- memcpy((char*)&g_conf.debug, (char*)&g_debug_after_conf.debug, size);
- dout(0) << "debug_after flipping debug settings" << dendl;
- }
-};
-
-
static void write_pid_file(int pid)
{
if (!g_conf.pid_file)
// some debug hackery?
if (g_conf.kill_after)
g_timer.add_event_after(g_conf.kill_after, new C_Die);
- if (g_conf.debug_after)
- g_timer.add_event_after(g_conf.debug_after, new C_Debug);
// go!
accepter.start();