indexer: Handle FTP MLSD errors

The mlsd() method from ftplib is a generator and is thus not supported
by the with_max_retries() decorator. Therefore, this method is overriden
by FTP_Retry to make the decorator work.
retry: Simplify the with_max_retries decorator
Use hostnames instead of IP address when available