added mirror spawn retry logic