Apart from the pubsub model of communication that libp2p provides, we also needed a 1→K form of communication where one node requests K other nodes for information and each of the K nodes replies independently using a direct 1-1 communication to the requesting node.
(K is a subset of N - the total number of nodes)
I don’t think this can be natively implemented using the pub-sub model since there are no topics which are known beforehand. Hence, to realize this on top of libp2p, we thought each node in the network could implement a random deterministic function to select k nodes (where k is a subset of K). The node then talks to these k nodes directly (1-1) which in turn, in addition to replying to requesting node, also choose their own k nodes from the K (where K is sent as part of the message metadata).
But I had the following question w.r.t this approach -
Will a node reuse its Peer connections (fanout or mesh connections or gossipsub connections)? Will the messages thus exchanged be added to the message cache implicitly?
your technical inputs will be greatly appreciated and help us make an informed choice.