Design phase in Erlang

Inswitch Solutions - Erlang Evaluation erlang@REDACTED
Fri Dec 6 16:16:26 CET 2002


Erlang Devs,

I have a procces in machine M1 which receives requests to run a state machine which I called "service". 
N clients send a request to machine M1 to execute the service.

>From the Erlang point of view, is it a good design to have a process for each client request (N processes) ?

Viewing it from another way, the service has the same code (logic) for each client but different instances for each client (the states).
Though, could be better to have those states for every client saved in some kind of structure and use the same code for every client by messages and recursion usage ( only 1 process) ?   N times reentrant code vs N processes.
It'd be harder to implement but I don't know how Erlang manages the N processes (N same execution routines) in memory when a huge number of processes are running.

I'd greatly appreciate some feedback about this.

Thanks,
Eduardo Figoli
INswitch solutions



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20021206/1025efae/attachment.htm>


More information about the erlang-questions mailing list