Retry mechanism with retry queue. 5 retries every 500ms