[erlang-questions] gen_server mailbox scans

Ben Hood 0x6e6562@REDACTED
Fri Jan 16 13:54:58 CET 2009


Chandru,

On Thu, Jan 15, 2009 at 11:34 AM, Chandru
<chandrashekhar.mullaparthi@REDACTED> wrote:
> I agree. If you are brave enough to have your own version of gen_server, may
> be you can have your message queue in an ordered_set ets table, instead of a
> queue. That way, you still keep the message queue in a separate area, and
> get all the power of ets. Will work better when you have large message
> queues to deal with.

Fair point. This could be an optimization that you could investigate.

> Is there no way you can throttle your clients before they send a message to
> the server process? That would make your life a lot easier.

Unfortuneately not. Dealing with viciforous clients purely
asynchronously is fine - it is just that we had to exend our server to
make a sychronous call to another server in the context of processing
of each message.

Ben



More information about the erlang-questions mailing list