Multiple servers: produce on server1 and consume on both server1 and server2

Here is my flow, can anybody tell me is that right?

  1. produce on server1 → (server1: router1)
  2. call pipeToRouter on server1 → (server1: router2, router3, …)
  3. call createPipeTransport on server1
  4. tell server2 to call createPipeTransport
  5. subscribe transport events each other
  6. consume current producer on server1
  7. tell server2 to produce the consumer that consumed by server1 → (server2: router1)
  8. call pipeToRouter on server2 → (server2: router2, router3, …)
  9. subscribe producer/consumer events each other

What is right and what is not depends on your use case. From the list above you probably also want to call PipeTransport.connect().

2 Likes

Thanks, I should call connect each other.