def METHOD_NAME(router, job):
    if not router.is_usable_for_task(job=job, logger=logger):
        job.mark_completed("Task cancelled")
        return False
    job.mark_running("Trying to connect...", object=router, logger=logger)
    success = router.METHOD_NAME()
    if success:
        job.mark_completed("Connection successful.", object=router, logger=logger)
    else:
        job.mark_failed("Connection failure.", object=router, logger=logger)
    return success