开发者

Multiples threads in FTP download: give each its own connection Vs. have them share one connection

开发者 https://www.devze.com 2023-04-06 11:27 出处:网络
In an application that downloads several files from an FTP server, it uses threads, ie. 5, to do its deed, and each one has its own connection (Apache Commons FTPClient.connect(url)).

In an application that downloads several files from an FTP server, it uses threads, ie. 5, to do its deed, and each one has its own connection (Apache Commons FTPClient.connect(url)).

Will it be the开发者_运维问答 same if the connection is shared instead? Is the ability to download files simultaneously be affected? Does the number of connections also dictate how well the app can maximize bandwidth (like maybe because an FTP server configure a bandwidth limit per connection it accepts, if there is such a thing)?

0

精彩评论

暂无评论...
验证码 换一张
取 消