How do two processes that are bound to the same port receive the same message?

I have two processes. both are listening on the same port.
This UDP multicast

is why both use the socket option SO_REUSEADDR

and join the multicast group before bind()

.

When I post a message to a multicast group ip:port

, only one of the processes receives the message.
How can they get them?

Thank.

+3


source to share


1 answer


I don't think this is possible, and I think that sometimes it is much more consistent. Perhaps you should implement a listener (which will listen on a port) that will propagate messages to other processes through interprocess communication (pipes for example).



-1


source







All Articles