Say I have two streams:
Stream 1: [1,3],[2,4]
Stream 2: [2,5],[3,2]
A regular merge would produce a Stream 3, like this:
[1,3],[2,4],[2,5],[3,2]
I would like to merge the stream whilst preserving the order in which the
tuple was emitted, so if [2,5]
was emitted at time 1, [1,3]
was emitted at
time 2, [3,2]
at time 3 and [2,4]
at time 4, the resulting stream would
be:
[2,5],[1,3],[3,2],[2,4]
Is there anyway way to do this and, if so, how? Some sample code would be appreciated as I'm a complete Trident rookie who has recently been thrust into a Trident based project.
Thanks in advance for your help,
Eli