Transform this Exchange to another Exchange where queueing, flow control and transformation of this I
and W
is controlled by supplied WyeW.
Transform this Exchange to another Exchange where queueing, flow control and transformation of this I
and W
is controlled by supplied WyeW.
Note this allows for fine-grained flow-control of written W
to server based on Int passed to left side of
supplied WyeW that contains actual size of queued values to be written to server.
WyeW to control queueing, flow control and transformation
uses provided function f
to be applied on any I
received
applies provided function to any W2
that has to be written to provide an W
Creates new exchange, that will pipe read values through supplied r
and write values through w
Creates new exchange, that will pipe read values through supplied r
and write values through w
Process1 to use on all read values
Process1 to use on all written values
Creates exchange that pipe
read I
values through supplied p1.
Creates exchange that pipe
read I
values through supplied p1.
Process1 to be used when reading values
Creates new exchange, that pipes all values to be sent through supplied p1
Process reading values from remote system
Transforms this exchange to another exchange, that for every received I
will consult supplied Writer1
and eventually transforms I
to I2
or to W
that is sent to remote system.
Transforms this exchange to another exchange, that for every received I
will consult supplied Writer1
and eventually transforms I
to I2
or to W
that is sent to remote system.
Please note that if external system is slow on reading W
this can lead to excessive heap usage. If you
want to avoid for this to happen, please use flow
instead.
Writer that processes received I
and either echoes I2
or writes W
to external system
Runs supplied Process of W
values by sending them to remote system.
Runs supplied Process of W
values by sending them to remote system.
Any replies from remote system are received as I
values of the resulting process.
Please note this will terminate by default after Left side (receive) terminates.
If you want to terminate after Right side (W) terminates, supply terminateOn with Request.R
or Request.Both
to
terminate on Right or Any side respectively
Process of W
values to send
Terminate on Left side (receive), Right side (W) or Any side terminates
Creates Exchange that runs read I
through supplied effect channel.
Creates Exchange that runs read I
through supplied effect channel.
Channel producing process of I2
for each I
received
Process writing values to remote system
Transform this Exchange to another Exchange where queueing, and transformation of this I
and W
is controlled by supplied WyeW.
Transform this Exchange to another Exchange where queueing, and transformation of this I
and W
is controlled by supplied WyeW.
Please note the W
queue of values to be sent to server is unbounded any may cause excessive heap usage, if the
remote system will read W
too slow. If you want to control this flow, use rather flow
.
WyeW to control queueing and transformation
Exchange represents interconnection between two systems. So called remote is resource from which program receives messages of type
I
and can send to it messages of typeO
.Typically this can be sort of connection to external system, like for example tcp connection to internet server.
Exchange allows combining this pattern with Processes and allows to use different combinators to specify the Exchange behaviour.
Exchange is currently specialized to
scalaz.concurrent.Task
values read from remote system
values written to remote system
Process reading values from remote system
Process writing values to remote system