Hello all,
Introduction
First, I just started working with the Kazoo/Kamailio/FreeSWITCH stack and recently started learning some Erlang for the greater good; please be patient.
The company I work at uses an old version of Kazoo (3.18), and they have created a few custom modules (e.g., conference) in the past that are working to this day. Unfortunately, all developers with experience with this stack - and programmed these modules - are no longer around. Due to the growth the company has experienced, the number of clients rose considerably, and now our system is having troubles during peak hours (i.e., conferencing, among other things, does not work).
Question
I saw that the log library used by Kazoo in this version is lager; since in production the default log level is ERROR, I would like to raise the log level to DEBUG for the specific modules used in conferences. The default log backend used in our application is the console.
What was tried
Lager provides a way to trace a specific module with the desired log level, but every time I try it, everything else seems to stop. This is how I tried:
echo '{ok, Trace} = lager:trace_file("log/conference.log", [{module, conference}], debug), Trace.' | ./erl_call -e -c XXX -n whistle_apps -h command_node
I followed the documentation of erl_call of the exact version present in the system. Once I run this, all the apps stop responding, and the only way to get things working again is to restart the whole process. Using lager:clear_all_traces and lager:stop_trace do not help.
Finally
I just started, so I am full of questions. Am I going in the wrong direction? Can I do what I am trying to do? Does Kazoo provide another way of doing this? If anyone can offer a little help, it would be fantastic.
Best regards,
Eduardo Almeida.