I use RemoteChannels as Communication Queues between processes.
My problem is that tasks who are receiving and sending data via RemoteChannels using put! or take!
do not surrender its control until data transferring finishes.
And I do not know whether this operation is normal.
I asked this before, I have not got any answer.
So, I wonder if this behavior is intended or will be corrected not to keep its control during communication in the future.
I haven’t used
RemoteCahnnels, but ordinary
Channels have configurable capacity - they allow you to send up to a certain number of objects and then block until somebody reads from the channel. This works well in practice - in normal circumstances sender and receiver work concurrently, so when sender gets blocked, receiver immediately starts reading and vice versa.
With remote communication it should work even better - sender and receiver can work in parallel, writing and reading simultaneously, so the channel may even never get filled.
Consider an alternative option when sender is never blocked and continues writing data disregarding whether anybody reads them. Where the data should go? Should it be thrown away or collected in channel / network buffer until it blows up? For most systems both options are unsuitable, so channels just block control flow until the situation is resolved.