Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
3.8k views
in .NET FTP by
I noticed that the documentation says that edtFTPnet is not thread safe. Could someone please clarify this for me? Does this mean that the same instance of the edtFTPnet client should not be accessed from multiple threads? Or does it mean that multiple instances cannot be used at the same time?

For example, I am writing a program that downloads a set of about 20 files from a group of devices. I am currently going to each device, downloading its files, and moving sequentially to the next device using a single client. Each device takes about 5 seconds to get all the files, so for a large number of devices, it will take a while. If I created around 4 or 5 threads, each with its own unique edtFTPnet client instance that is talking to a different device, and had them all running at the same time, I figured I could drastically cut the time it takes. Is this a valid solution and is there any problems with this? Again, each thread would have it's own unique instance of the client.

2 Answers

0 votes
by (161k points)
Sounds like a good solution, can't see any problems with it.

For example, I am writing a program that downloads a set of about 20 files from a group of devices. I am currently going to each device, downloading its files, and moving sequentially to the next device using a single client. Each device takes about 5 seconds to get all the files, so for a large number of devices, it will take a while. If I created around 4 or 5 threads, each with its own unique edtFTPnet client instance that is talking to a different device, and had them all running at the same time, I figured I could drastically cut the time it takes. Is this a valid solution and is there any problems with this? Again, each thread would have it's own unique instance of the client.
0 votes
by
Great. Thanks for the input and help.

Categories

...