I have been going through the chapter Rage Against The Finite State Machine of the tutorial, and it uses gen_fsm, which has been deprecated in favor o ...
I have been going through the chapter Rage Against The Finite State Machine of the tutorial, and it uses gen_fsm, which has been deprecated in favor o ...
I have following code: Then in gen_fsm I handle this messages as: Code used to send messages with delays up to 48 hours. Most of the time everyt ...
I have a simple_one_for_one supervisor which has gen_fsm children. I want each gen_fsm child to send a message only on the last time it terminates. Is ...
I am developing a solution that queries a SOAP web service for certain transactions. Once retrieved, these transactions are meant to be saved in a dat ...
I'm creating a generic Erlang server that should be able to handle hundreds of client connections concurrently. For simplicity, let's suppose that the ...
I have 3 modules: calculadora, log_calculadora and supervisor_calculadora. Calculadora is just a simple calculator that makes sum, subtraction, multip ...
Assume my initial state is "Rule1" and it keeps toggling between states, If its in "Rule1" , it moves to "Rule2" and vice versa , based on some cond ...
There is an locked door example about gen_fsm in the Elrang Otp System Documentation. I have a question about timeout. I will copy the code here first ...
What is the most recommended way in Erlang to ensure that some process exists before sending a message / event to it? In my scenario I am starting pro ...
We have a fairly large USSD application that uses Erlang's gen_fsm module to manage the menu options. The current version has a single menus_fsm.erl ...
I would like to know what is the suggested way (if any) to move a gen_server/gen_fsm from erlang node A to erlang node B preserving its internal state ...
I have a question on gen_fsm timeout. Let's say you have a set of gen_fsm with two states (in future can be more): idle which is the starting state an ...
I want my FSM to terminate any time event doesn't come after specified amout of time in every state. I can achieve such a scenario only in case ther ...
I would like to use is_flag_active() function inside one of my state's on_entry template function: However I got the following compile error: Ho ...
After checking out Gen_Fsm and Gen_Server documents, I found that, more or less, they act as similar behavior. In my opinion, if there is one loop fun ...
I'm currently in a project making a gameserver. Every player is supposed have an own process with gen_fsm behavior. To start gen_fsm with start/3 we n ...
I noticed that messages sent to the pid of a gen_fsm process are matched in the state callbacks as events. Is this just accidental or can I rely on th ...
I'm looking for an example of a simple FSM implemented in Erlang using the gen_fsm from OTP. ...
Normally if I'd like to have an Erlang process timeout I would use the following construct: Is there a similar mechanism in the OTP servers such as ...