How to add debugger app in the rebar.config in MongooseIM?










0















I am using MAC OS 10.14 with MongooseIM. I want to use debugger in MongooseIM. When I execute im(). in MongooseIm shell, I get the following error:



Call to i:im/0 in application debugger failed. ok



I can verify that I can run im(). in the erlang shell $ erl. It seems I have to enable the debugger in the MongooseIM but I don't know how to do that. I failed to find it in Erlang/Ejabberd/MongooseIM docs. I have also read the following related to this :



Call to i:im() in application debugger failed in mongooseim
https://github.com/esl/MongooseIM/issues/1788



As per the second URL, I need to add debugger app in the rebar.config in MongooseIM but I don't know how, please help.










share|improve this question






















  • I am using $ sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl live to start the MongooseIm server and then I try im(). inside the live shell

    – Shubham1164
    Nov 15 '18 at 6:04











  • Since the live shell is working fine. But when I use $sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl debug, I get some the following error *** ERROR: Shell process terminated! (^G to start new job) ***

    – Shubham1164
    Nov 15 '18 at 6:06











  • You can follow this suggestion - github.com/esl/MongooseIM/issues/1788#issuecomment-378195556 - and add the debugger application to rebar.config, but please see my answer below for the suggested alternative.

    – erszcz
    Nov 15 '18 at 9:56















0















I am using MAC OS 10.14 with MongooseIM. I want to use debugger in MongooseIM. When I execute im(). in MongooseIm shell, I get the following error:



Call to i:im/0 in application debugger failed. ok



I can verify that I can run im(). in the erlang shell $ erl. It seems I have to enable the debugger in the MongooseIM but I don't know how to do that. I failed to find it in Erlang/Ejabberd/MongooseIM docs. I have also read the following related to this :



Call to i:im() in application debugger failed in mongooseim
https://github.com/esl/MongooseIM/issues/1788



As per the second URL, I need to add debugger app in the rebar.config in MongooseIM but I don't know how, please help.










share|improve this question






















  • I am using $ sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl live to start the MongooseIm server and then I try im(). inside the live shell

    – Shubham1164
    Nov 15 '18 at 6:04











  • Since the live shell is working fine. But when I use $sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl debug, I get some the following error *** ERROR: Shell process terminated! (^G to start new job) ***

    – Shubham1164
    Nov 15 '18 at 6:06











  • You can follow this suggestion - github.com/esl/MongooseIM/issues/1788#issuecomment-378195556 - and add the debugger application to rebar.config, but please see my answer below for the suggested alternative.

    – erszcz
    Nov 15 '18 at 9:56













0












0








0








I am using MAC OS 10.14 with MongooseIM. I want to use debugger in MongooseIM. When I execute im(). in MongooseIm shell, I get the following error:



Call to i:im/0 in application debugger failed. ok



I can verify that I can run im(). in the erlang shell $ erl. It seems I have to enable the debugger in the MongooseIM but I don't know how to do that. I failed to find it in Erlang/Ejabberd/MongooseIM docs. I have also read the following related to this :



Call to i:im() in application debugger failed in mongooseim
https://github.com/esl/MongooseIM/issues/1788



As per the second URL, I need to add debugger app in the rebar.config in MongooseIM but I don't know how, please help.










share|improve this question














I am using MAC OS 10.14 with MongooseIM. I want to use debugger in MongooseIM. When I execute im(). in MongooseIm shell, I get the following error:



Call to i:im/0 in application debugger failed. ok



I can verify that I can run im(). in the erlang shell $ erl. It seems I have to enable the debugger in the MongooseIM but I don't know how to do that. I failed to find it in Erlang/Ejabberd/MongooseIM docs. I have also read the following related to this :



Call to i:im() in application debugger failed in mongooseim
https://github.com/esl/MongooseIM/issues/1788



As per the second URL, I need to add debugger app in the rebar.config in MongooseIM but I don't know how, please help.







debugging erlang ejabberd mongoose-im






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 15 '18 at 6:01









Shubham1164Shubham1164

7317




7317












  • I am using $ sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl live to start the MongooseIm server and then I try im(). inside the live shell

    – Shubham1164
    Nov 15 '18 at 6:04











  • Since the live shell is working fine. But when I use $sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl debug, I get some the following error *** ERROR: Shell process terminated! (^G to start new job) ***

    – Shubham1164
    Nov 15 '18 at 6:06











  • You can follow this suggestion - github.com/esl/MongooseIM/issues/1788#issuecomment-378195556 - and add the debugger application to rebar.config, but please see my answer below for the suggested alternative.

    – erszcz
    Nov 15 '18 at 9:56

















  • I am using $ sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl live to start the MongooseIm server and then I try im(). inside the live shell

    – Shubham1164
    Nov 15 '18 at 6:04











  • Since the live shell is working fine. But when I use $sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl debug, I get some the following error *** ERROR: Shell process terminated! (^G to start new job) ***

    – Shubham1164
    Nov 15 '18 at 6:06











  • You can follow this suggestion - github.com/esl/MongooseIM/issues/1788#issuecomment-378195556 - and add the debugger application to rebar.config, but please see my answer below for the suggested alternative.

    – erszcz
    Nov 15 '18 at 9:56
















I am using $ sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl live to start the MongooseIm server and then I try im(). inside the live shell

– Shubham1164
Nov 15 '18 at 6:04





I am using $ sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl live to start the MongooseIm server and then I try im(). inside the live shell

– Shubham1164
Nov 15 '18 at 6:04













Since the live shell is working fine. But when I use $sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl debug, I get some the following error *** ERROR: Shell process terminated! (^G to start new job) ***

– Shubham1164
Nov 15 '18 at 6:06





Since the live shell is working fine. But when I use $sudo /Users/MAC/Documents/Workspace/MongooseIm/MongooseIM/_build/prod/rel/mongooseim/bin/mongooseimctl debug, I get some the following error *** ERROR: Shell process terminated! (^G to start new job) ***

– Shubham1164
Nov 15 '18 at 6:06













You can follow this suggestion - github.com/esl/MongooseIM/issues/1788#issuecomment-378195556 - and add the debugger application to rebar.config, but please see my answer below for the suggested alternative.

– erszcz
Nov 15 '18 at 9:56





You can follow this suggestion - github.com/esl/MongooseIM/issues/1788#issuecomment-378195556 - and add the debugger application to rebar.config, but please see my answer below for the suggested alternative.

– erszcz
Nov 15 '18 at 9:56












1 Answer
1






active

oldest

votes


















1














i:im() is a stepwise debugger (like gdb, lldb, or pdb which allow for setting breakpoints, running a program, pausing execution, etc) based on wxWidgets graphical user interface library. MongooseIM is a server - it does not bundle wxWidgets, because it does not have a graphical interface at all.



Due to the nature of the Erlang VM, where a lot of concurrent activities happen side by side, a stepwise debugger is not the best tool for the job. For example, setting a breakpoint in a process which is called via gen_server:call() would make the call time out, leading to a cascade of errors possibly irrelevant to the problem being debugged.



However, the Erlang VM has a builtin debugging facility more suitable to its concurrent nature - a tracing debugger. Tracing does not allow for breakpoints or pausing execution. Instead, it records (a subset of all) the exact events
happening in the system and prints/saves them for a posteriori inspection.



This video and transcript provide a brief introduction to tracing on the Erlang VM (in Elixir syntax), while Mats Cronqvist, one of the Erlang veterans, elaborates on the subject in his Erlang User Conference 2014 talk Taking the printf out of printf debugging.



That being said, MongooseIM ships with two interfaces to the tracing mechanism:



  • dbg - the standard OTP interface - this SO post shows its basics - be careful if tracing in production, since dbg does not provide any safety mechanisms, so it's possible to overload a production system,


  • recon - a way more user friendly and safe for production tracing library, with outstanding documentation. This is probably your best choice when the ease of applicability and the set of features are considered.






share|improve this answer























  • Thanks erszcz. I will definitely give a try to recon. :)

    – Shubham1164
    Nov 16 '18 at 16:10










Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53313325%2fhow-to-add-debugger-app-in-the-rebar-config-in-mongooseim%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1














i:im() is a stepwise debugger (like gdb, lldb, or pdb which allow for setting breakpoints, running a program, pausing execution, etc) based on wxWidgets graphical user interface library. MongooseIM is a server - it does not bundle wxWidgets, because it does not have a graphical interface at all.



Due to the nature of the Erlang VM, where a lot of concurrent activities happen side by side, a stepwise debugger is not the best tool for the job. For example, setting a breakpoint in a process which is called via gen_server:call() would make the call time out, leading to a cascade of errors possibly irrelevant to the problem being debugged.



However, the Erlang VM has a builtin debugging facility more suitable to its concurrent nature - a tracing debugger. Tracing does not allow for breakpoints or pausing execution. Instead, it records (a subset of all) the exact events
happening in the system and prints/saves them for a posteriori inspection.



This video and transcript provide a brief introduction to tracing on the Erlang VM (in Elixir syntax), while Mats Cronqvist, one of the Erlang veterans, elaborates on the subject in his Erlang User Conference 2014 talk Taking the printf out of printf debugging.



That being said, MongooseIM ships with two interfaces to the tracing mechanism:



  • dbg - the standard OTP interface - this SO post shows its basics - be careful if tracing in production, since dbg does not provide any safety mechanisms, so it's possible to overload a production system,


  • recon - a way more user friendly and safe for production tracing library, with outstanding documentation. This is probably your best choice when the ease of applicability and the set of features are considered.






share|improve this answer























  • Thanks erszcz. I will definitely give a try to recon. :)

    – Shubham1164
    Nov 16 '18 at 16:10















1














i:im() is a stepwise debugger (like gdb, lldb, or pdb which allow for setting breakpoints, running a program, pausing execution, etc) based on wxWidgets graphical user interface library. MongooseIM is a server - it does not bundle wxWidgets, because it does not have a graphical interface at all.



Due to the nature of the Erlang VM, where a lot of concurrent activities happen side by side, a stepwise debugger is not the best tool for the job. For example, setting a breakpoint in a process which is called via gen_server:call() would make the call time out, leading to a cascade of errors possibly irrelevant to the problem being debugged.



However, the Erlang VM has a builtin debugging facility more suitable to its concurrent nature - a tracing debugger. Tracing does not allow for breakpoints or pausing execution. Instead, it records (a subset of all) the exact events
happening in the system and prints/saves them for a posteriori inspection.



This video and transcript provide a brief introduction to tracing on the Erlang VM (in Elixir syntax), while Mats Cronqvist, one of the Erlang veterans, elaborates on the subject in his Erlang User Conference 2014 talk Taking the printf out of printf debugging.



That being said, MongooseIM ships with two interfaces to the tracing mechanism:



  • dbg - the standard OTP interface - this SO post shows its basics - be careful if tracing in production, since dbg does not provide any safety mechanisms, so it's possible to overload a production system,


  • recon - a way more user friendly and safe for production tracing library, with outstanding documentation. This is probably your best choice when the ease of applicability and the set of features are considered.






share|improve this answer























  • Thanks erszcz. I will definitely give a try to recon. :)

    – Shubham1164
    Nov 16 '18 at 16:10













1












1








1







i:im() is a stepwise debugger (like gdb, lldb, or pdb which allow for setting breakpoints, running a program, pausing execution, etc) based on wxWidgets graphical user interface library. MongooseIM is a server - it does not bundle wxWidgets, because it does not have a graphical interface at all.



Due to the nature of the Erlang VM, where a lot of concurrent activities happen side by side, a stepwise debugger is not the best tool for the job. For example, setting a breakpoint in a process which is called via gen_server:call() would make the call time out, leading to a cascade of errors possibly irrelevant to the problem being debugged.



However, the Erlang VM has a builtin debugging facility more suitable to its concurrent nature - a tracing debugger. Tracing does not allow for breakpoints or pausing execution. Instead, it records (a subset of all) the exact events
happening in the system and prints/saves them for a posteriori inspection.



This video and transcript provide a brief introduction to tracing on the Erlang VM (in Elixir syntax), while Mats Cronqvist, one of the Erlang veterans, elaborates on the subject in his Erlang User Conference 2014 talk Taking the printf out of printf debugging.



That being said, MongooseIM ships with two interfaces to the tracing mechanism:



  • dbg - the standard OTP interface - this SO post shows its basics - be careful if tracing in production, since dbg does not provide any safety mechanisms, so it's possible to overload a production system,


  • recon - a way more user friendly and safe for production tracing library, with outstanding documentation. This is probably your best choice when the ease of applicability and the set of features are considered.






share|improve this answer













i:im() is a stepwise debugger (like gdb, lldb, or pdb which allow for setting breakpoints, running a program, pausing execution, etc) based on wxWidgets graphical user interface library. MongooseIM is a server - it does not bundle wxWidgets, because it does not have a graphical interface at all.



Due to the nature of the Erlang VM, where a lot of concurrent activities happen side by side, a stepwise debugger is not the best tool for the job. For example, setting a breakpoint in a process which is called via gen_server:call() would make the call time out, leading to a cascade of errors possibly irrelevant to the problem being debugged.



However, the Erlang VM has a builtin debugging facility more suitable to its concurrent nature - a tracing debugger. Tracing does not allow for breakpoints or pausing execution. Instead, it records (a subset of all) the exact events
happening in the system and prints/saves them for a posteriori inspection.



This video and transcript provide a brief introduction to tracing on the Erlang VM (in Elixir syntax), while Mats Cronqvist, one of the Erlang veterans, elaborates on the subject in his Erlang User Conference 2014 talk Taking the printf out of printf debugging.



That being said, MongooseIM ships with two interfaces to the tracing mechanism:



  • dbg - the standard OTP interface - this SO post shows its basics - be careful if tracing in production, since dbg does not provide any safety mechanisms, so it's possible to overload a production system,


  • recon - a way more user friendly and safe for production tracing library, with outstanding documentation. This is probably your best choice when the ease of applicability and the set of features are considered.







share|improve this answer












share|improve this answer



share|improve this answer










answered Nov 15 '18 at 9:51









erszczerszcz

1,059715




1,059715












  • Thanks erszcz. I will definitely give a try to recon. :)

    – Shubham1164
    Nov 16 '18 at 16:10

















  • Thanks erszcz. I will definitely give a try to recon. :)

    – Shubham1164
    Nov 16 '18 at 16:10
















Thanks erszcz. I will definitely give a try to recon. :)

– Shubham1164
Nov 16 '18 at 16:10





Thanks erszcz. I will definitely give a try to recon. :)

– Shubham1164
Nov 16 '18 at 16:10



















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53313325%2fhow-to-add-debugger-app-in-the-rebar-config-in-mongooseim%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Top Tejano songwriter Luis Silva dead of heart attack at 64

ReactJS Fetched API data displays live - need Data displayed static

Evgeni Malkin