set maxSockets to the number of instances we use
simpler callback handling