0

I have an issue that is driving me crazy! Both design-wise and tech-wise. I have a need to listen to a LOT of multicast addresses. They are divided into 3 groups per item that I am monitoring/collecting. I have gone down the road of having one process spin-up 100 threads. Each thread uses 2 ports, and three addresses/groups. (2 of the groups are on same port) I am using MulticastChannel for each port, and using SELECT to monitor for data. (I have used datagram but found NIO MulticastChannel much better). Anyway, I am seeing issues where I can subscribe to about a thousand of these threads, and data hums along nicely. Problem is, after a while I will have some of them stop receiving data. I have confirmed with the system (CentOS) that I am still subscribed to these addresses, but data just stops. I have monitors in my threads that monitor data drops and out-of-order via the RTP headers. When I detect that a thread has stopped getting data, I do a DROP/JOIN, and data then resumes.

I am thinking that a router in my path is dropping my subscription. I am at my wits end writing code to stabilize this process.

Has anyone ever sent IGMP joins out the network to keep the data flowing? Is this possible, or even reasonable.

BTW: The computer is a HP DL380 Gen-9 with a 10G fiber connection to a 6509 switch.

Any pointers on where to look would really help.

Please do not ask for any code examples.

Wayne
  • 85
  • 1
  • 6

1 Answers1

2

The joinGroup() operation already sends out IGMP requests on the network. It shouldn't be necessary to send them out yourself, and it isn't possible in pure Java anyway.

You could economize on sockets and threads. A socket can join up to about 20 groups on most operating systems, and if you're using NIO and selectors there's no need for more than one thread anyway.

I have used datagram but found NIO MulticastChannel much better).

I don't know what this means. If you're referring to DatagramSocket, you can't use it for receiving multicasts, so the sentence is pointless. If you aren't, the sentence is meaningless.

user207421
  • 305,947
  • 44
  • 307
  • 483