Hello friends, I have a issue with the FTP Activity pack. I’m trying to download about 1600 files from an FTP-server, but the download speed is very slow… perhaps 3-4 files a minute. The problem is not the connection as it is lightning fast when using FileZilla.
I’m using the Enumerate files and Download activities as I don’t want to download all the subfolders in the target-FTP directory. This of course means that I have to use a for-loop where I check if the FTP-element is a directory or not, and if it is not a directory I’ll download it.
If I don’t use Enumerate files and just download everything in the target folder, then the download is super-fast… but then I also will get all the subfolders which I don’t need.
So the problem seems to be that I’m calling the Download-activity 1600 times. Is there some other way I can download only the files and not the subfolders in the target FTP-directory?
as I checked with the UiPath.FTP.Activities I could see download files, and enumerate objects, no enumerate files, could you please let us know which package you are using and try to update the package if you are using UiPath.FTP.Activities.
I have unchecked the IncludeSubDirectories-checkbox. No change.
The problem is not the Enumerate files activity, I can enumerate all files and folders in the target FTP-directory without any issues. The problem is downloading the individual files afterwards. Or perhaps I misunderstood your explanation!?
To clarify, this is what I’m doing:
First I open an FTP session.
Then I use Enumerate files to get a DataTable with all files and folders in the target FTP-directory.
The I use the For Each Row activity to iterate over said DataTable (with all files and folders).
If the element is a file, then I download it.
If the element is a directory, then I ignore it.
I’m using row(“IsDirectory”) to check if element is a directory or not.
There is currently about 1600 files and about 40 directories in the target FTP-directory.
When I run my workflow, I can see that the download is very slow… maybe 20 files a minute. This is perhaps because I’m calling the Download-activity 1600 times!?
If I don’t use enumerate files and just use the Download activity to download all files and folders, then the download is very fast (hundreds of files a minute). The problem is that the subfolders in my FTP-directory contains lots of files that I don’t need, so I don’t want to download them as well.
The looping is not the problem either. If I just loop through the table using the For Each Row I can log the fullName all elements elements in one second. The problem seems to be the Download-activity.
Since you are Downloading each file, it is taking more time to establish the connection with the FTP server and download the file. You need to download all the files and delete the unwanted files once the download completed, if you want it to fast.
Yeah I suspected as much. My problem is that the FTP-folder is growing each day with new subfolders containing many thousands of files, so downloading it all each time the process runs is unfortunately not an option when I’m only interested in the files in the “root” FTP-folder.
Anyways, then I know the limitations. I will try to find another way to solve my problem then.
Thanks for your time @sarathi125, it is much appreciated.