From c0d51b83f42a7b0161aa84f3b146db846e9f49ec Mon Sep 17 00:00:00 2001 From: Andrew Thompson Date: Fri, 20 Aug 2010 02:32:20 -0400 Subject: [PATCH] Improve some logging to include UUIDs --- src/mod/event_handlers/mod_erlang_event/handle_msg.c | 2 +- src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mod/event_handlers/mod_erlang_event/handle_msg.c b/src/mod/event_handlers/mod_erlang_event/handle_msg.c index 38c0e4e4eb..40d5455e7d 100644 --- a/src/mod/event_handlers/mod_erlang_event/handle_msg.c +++ b/src/mod/event_handlers/mod_erlang_event/handle_msg.c @@ -929,7 +929,7 @@ static switch_status_t handle_ref_tuple(listener_t *listener, erlang_msg * msg, return SWITCH_STATUS_SUCCESS; } switch_mutex_unlock(se->spawn_reply->mutex); - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "get_pid came in too late for %s\n", hash); + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "get_pid came in too late for %s; %s\n", hash, se->uuid_str); break; } } diff --git a/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c b/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c index 60acc96517..0e618c4a70 100644 --- a/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c +++ b/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c @@ -1300,7 +1300,7 @@ session_elem_t *attach_call_to_spawned_process(listener_t *listener, char *modul ei_x_encode_tuple_header(&rbuf, 4); ei_x_encode_atom(&rbuf, "get_pid"); - _ei_x_encode_string(&rbuf, switch_core_session_get_uuid(session)); + _ei_x_encode_string(&rbuf, session_element->uuid_str); ei_x_encode_ref(&rbuf, &ref); ei_x_encode_pid(&rbuf, ei_self(listener->ec)); /* should lock with mutex? */ @@ -1326,13 +1326,13 @@ session_elem_t *attach_call_to_spawned_process(listener_t *listener, char *modul switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "wtf\n"); if (!p->pid) { p->state = reply_timeout; - switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Timed out when waiting for outbound pid %s\n", hash); + switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Timed out when waiting for outbound pid %s %s\n", hash, session_element->uuid_str); remove_session_elem_from_listener_locked(listener, session_element); destroy_session_elem(session_element); return NULL; } - switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "got pid! %s\n", hash); + switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "got pid! %s %s\n", hash, session_element->uuid_str); session_element->process.type = ERLANG_PID; memcpy(&session_element->process.pid, p->pid, sizeof(erlang_pid));