[zeromq-dev] Maximum number of zactors?

Doron Somech somdoron at gmail.com
Thu May 16 18:01:15 CEST 2019


File descriptor is being used for signaling.
If zactor would use thread safe sockets it would be unlimited.

On Thu, May 16, 2019, 18:51 Arnaud Loonstra <arnaud at sphaero.org> wrote:

> Hi all,
>
> I'm currently stress testing a setup with actors. What's the maximum
> number of running zactors? As it's using inproc no file descriptors are
> involved. I'm using this test:
>
>      // mega zactor test
>      zlist_t *spawned_act = zlist_new();
>      for (int i=0;i<507;i++)
>      {
>          zactor_t *act = zactor_new(echo_actor, "Hello actor");
>          assert(act);
>          zlist_append(spawned_act, act);
>      }
>      while(zlist_size(spawned_act) > 0)
>      {
>          zactor_t *dstr = zlist_pop(spawned_act);
>          zactor_destroy(&dstr);
>      }
>
> If I go beyond 507 actors I receive an assert:
>
> src/zsock.c:88: zsock_new_checked: Assertion `self->handle' failed.
>
> Which traces back to:
>
> self->handle = zsys_socket (type, filename, line_nbr);
>
> Which is a wrapper for creating a zmq socket.
>
> Any ideas why there's is this limit of 507 actors?
>
> I also tried with my own actor library which adds pub/sub sockets to the
> actor. I then have a maximum of 252 actors.
>
> Rg,
>
> Arnaud
>
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> https://lists.zeromq.org/mailman/listinfo/zeromq-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20190516/8607a5c1/attachment.htm>


More information about the zeromq-dev mailing list