Hi,
I get by websocket Json data . I have 10K different packs, but the number of this different kind of packs is constant ( 10k) .
E.x of receiving
[pack1]
[pack2]
[pack3]
…
[pack1]
[pack3]
[pack2]
…
[pack10k]
[pack5]
[pack99]
Via websocket I receive in one second about 1K different packs .
I have 100 RECEIVERS of this packs and each receiver has Agent dedicated to specific packs .
RECEIVER 1
----- AgentForPack1
----- AgentForPack2
…
----- AgentForPack10K
RECEIVER 2
----- AgentForPack1
----- AgentForPack2
…
----- AgentForPack10K
RECEIVER 100
…
Each pack must be calculated by each receiver (by Agent from Receiver dedicated to specific pack, then Agent holds new calculated state) .
Question is : which way is better to code this problem
SOLUTION ONE :
One channel:onetopic which spreads out each PACK to each RECEIVER, then each receiver does some calculation on this pack (via Agent)
SOLUTION TWO :
channel:10Ktopics (each topic is dedicated to specific PACK) , then each receiver is subscribed to 10K channel:10Ktopics
Thanks in advance for answer