Close socket after all splits are sent to a worker