I see #381 has been concluded, but as I'm re-implementing in Haskell a swarm control infrastructure managing clusters of number crunching servers originally implemented in Python, I miss basic UDP mcast support very much. No streaming requirement, just job announcement and discovery with single frag UDP packets, further comm always resorts to TCP connections.
network-multicast seemingly will work for me, but it feels weird I'd need another separate package to do that.
As for API issue, can you consider add one like setSocketOptionBuf, or a same named one in ByteString module? Like that we have sendBuf and send in ByteString superseding that in top-level ?
In Python it's all handled by socket package like:
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
if is_mcast:
# join the multicast group
group = socket.inet_pton(socket.AF_INET, swarm_ip)
ifa = socket.inet_pton(socket.AF_INET, self.mcast_through or "0.0.0.0")
mreq = group + ifa
sock.setsockopt(socket.IPPROTO_IP, socket.IP_ADD_MEMBERSHIP, mreq)
sock.bind((swarm_ip, self.swarm_port))
64-bit suffices with mreq for IPv4, so event an Int may probably work, but may be not a good idea.
I see #381 has been concluded, but as I'm re-implementing in Haskell a swarm control infrastructure managing clusters of number crunching servers originally implemented in Python, I miss basic UDP mcast support very much. No streaming requirement, just job announcement and discovery with single frag UDP packets, further comm always resorts to TCP connections.
network-multicast seemingly will work for me, but it feels weird I'd need another separate package to do that.
As for API issue, can you consider add one like
setSocketOptionBuf, or a same named one in ByteString module? Like that we havesendBufandsendin ByteString superseding that in top-level ?In Python it's all handled by socket package like:
64-bit suffices with
mreqfor IPv4, so event an Int may probably work, but may be not a good idea.