[WFLY-490] If rename fails, delete file once it has been copied