Close #169 调整与KNI保活模块的初始化位置到最后,避免在初始化过程中丢失连接。
This commit is contained in:
@@ -685,10 +685,6 @@ int main(int argc, char * argv[])
|
|||||||
g_default_proxy->scm_sender = sender_scm_init(main_profile, "kni", g_default_logger);
|
g_default_proxy->scm_sender = sender_scm_init(main_profile, "kni", g_default_logger);
|
||||||
CHECK_OR_EXIT(g_default_proxy->scm_sender != NULL, "Failed at creating scm sender, Exit.");
|
CHECK_OR_EXIT(g_default_proxy->scm_sender != NULL, "Failed at creating scm sender, Exit.");
|
||||||
|
|
||||||
/* Watchdog KNI */
|
|
||||||
g_default_proxy->watchdog_kni = watchdog_kni_create(g_default_proxy, main_profile, g_default_logger);
|
|
||||||
CHECK_OR_EXIT(g_default_proxy->watchdog_kni != NULL, "Failed at creating KNI watchdog, Exit.");
|
|
||||||
|
|
||||||
/* PLUGIN INIT */
|
/* PLUGIN INIT */
|
||||||
unsigned int plugin_iterator = 0;
|
unsigned int plugin_iterator = 0;
|
||||||
for (struct tfe_plugin * plugin_iter = tfe_plugin_iterate(&plugin_iterator);
|
for (struct tfe_plugin * plugin_iter = tfe_plugin_iterate(&plugin_iterator);
|
||||||
@@ -705,6 +701,10 @@ int main(int argc, char * argv[])
|
|||||||
ret = tfe_proxy_work_thread_run(g_default_proxy);
|
ret = tfe_proxy_work_thread_run(g_default_proxy);
|
||||||
CHECK_OR_EXIT(ret == 0, "Failed at creating thread. Exit.");
|
CHECK_OR_EXIT(ret == 0, "Failed at creating thread. Exit.");
|
||||||
|
|
||||||
|
/* Watchdog KNI */
|
||||||
|
g_default_proxy->watchdog_kni = watchdog_kni_create(g_default_proxy, main_profile, g_default_logger);
|
||||||
|
CHECK_OR_EXIT(g_default_proxy->watchdog_kni != NULL, "Failed at creating KNI watchdog, Exit.");
|
||||||
|
|
||||||
TFE_LOG_ERROR(g_default_logger, "Tango Frontend Engine initialized. ");
|
TFE_LOG_ERROR(g_default_logger, "Tango Frontend Engine initialized. ");
|
||||||
event_base_dispatch(g_default_proxy->evbase);
|
event_base_dispatch(g_default_proxy->evbase);
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user