[zeromq-dev] hold zactors in a zlist(x)_t
Kevin Sapper
kevinsapper88 at gmail.com
Mon Dec 28 20:51:41 CET 2020
Hi Juergen,
this will work just fine. Depending on the amount of actors performance
might be influenced because for every message you'll need to find the
correct actor in the list.
If performance is becoming an issue try try using a zhashx and use the
pointer address as key.
//Kevin
Juergen Gnoss <jgnoss at hotmail.com> schrieb am Mo., 28. Dez. 2020, 17:01:
> Thanks Arnaud,
>
> regarding the zpoller, yes I know them well, I use them all time.
> That said, my idea is, adding the actor to the poller after creating them.
> Then, if the poller triggers, I can iterate through the list to find out
> who sends that message.
>
> Ju
>
> ------------------------------
> *From:* zeromq-dev <zeromq-dev-bounces at lists.zeromq.org> on behalf of
> Arnaud Loonstra <arnaud at sphaero.org>
> *Sent:* Monday, December 28, 2020 8:34 AM
> *To:* zeromq-dev at lists.zeromq.org <zeromq-dev at lists.zeromq.org>
> *Subject:* Re: [zeromq-dev] hold zactors in a zlist(x)_t
>
> Seems OK to me, it's not invalid at least. What I do find puzzling is that
> you need the list to see if there are messages? You do know you can poll
> zactors using a zpoller?
>
> Rg,
>
> ArnaudOn Dec 28, 2020 12:43, Juergen Gnoss <jgnoss at hotmail.com> wrote:
> >
> > I need a bit of brainstorming, so, I just pop that question in the
> round.
> >
> >
> > I've a variable number of parameters for algorithms stored in a zconfig.
> >
> > On program start I need to go through that config and start an
> algorithm-actor for each parameter-set.
> >
> > Since this is very dynamic, it comes to my mind holding that actors in a
> zlist(x)_t.
> > How valid is that?
> >
> > I don't need to shuffle them around in the list, just add them,
> >
> > identify them if there is a msg coming from them and
> >
> > destroy them if no longer needed.
> >
> > If I implement a duplicator-, comparator- and the free-function, I
> should be fine.
> >
> >
> > Is that a valid way to go, or is there another suggestion.
> >
> >
> > Thanks
> >
> > Ju
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> https://lists.zeromq.org/mailman/listinfo/zeromq-dev
> _______________________________________________
> 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/20201228/88b66ba6/attachment.htm>
More information about the zeromq-dev
mailing list