According to Effective Acca, the balancing manager will become obsolete soon. I will start working on some (separate machines) producer / consumer code that handles workloads of completely different forms. What should i use?
I would like the producer to block (akka block or thread block, I don't care) ( similar to this question ), since it will go through 204,000 records from the database cursor: D
Writing a tablet for my own model seems too heavy. There should be something new in the pipeline that replaces the balancing manager.
Foolish notes for self-help.
What I'm trying to solve:
Write down as small a code as possible a consumer-producer system with 2 classes of actors that saturates the processing power of one machine. Also, do not send all the work from the consumer at a time, since a) there is a lot of work (I donβt know what the size limits of the child mailboxes are) and b) the work takes different forms.
Approaches / Assumptions
I have not seen an example with a balanced dispatcher, so my expectations regarding what it does and how it can be used are most likely distorted. The dispatcher seems to be a very understandable concept, tied to the entire system of actors, and the documentation indicates that all participants in a balanced dispatcher-based system should be able to process the same messages (or, in other words, be the same type of actor) ,
If this is true, the assumption does not actually display neatly for prod-cons, since the cons driver must be outside the actors system. as an actor on another system or a future request cycle when the application starts. The types of participants in the balancing manager can always have logic and types of messages to become a product, but this would be a rather unpleasant hack. Or, perhaps, when starting the actors system, there is a hook that can be used to completely fill the message queue (but again, this does not seem like a good way to do something). I conclude that a balanced dispatcher is really nasty.
The above assumption is incorrect, at the end of the router documentation there is the following:
At first glance, there seems to be an overlap between BalancingDispatcher and Routers, but they complement each other. The balancing manager is responsible for managing the actors, while the routers are responsible for deciding which message is sent there. A router may also have children that span multiple acting systems, even remote ones, but the dispatcher lives within a single actor system.
Which view will confirm my question: D
Ok, so the child entities defined using the balancing manager + circular router can do the trick. But where is the size of the attached shared mailbox (from the overview below, the optional mailboxcapacity and mailbox-type options seem to do this).
References
There are three concepts here. Dispatcher , Router and mailbox .
general review
The latest documentation linked above does not mention that the balancing manager is out of date.