Fix work service and ImportDB Job. Added logic to limit the number
of rename attempts to 5