Use threads for UDP sockets.