SFTP - Incremental File Downloads

0
We have a requirement to interface with an SFTP server. That Server will host a file that is being continuously written to throughout the day. What I need to be able to do is access that file every 10 minutes or so and perform an incremental download of the contents that have updated since the last time our application accessed that file. Is this something that I will be able to achieve using your 'Secure .NET SFTP Library' ???
 
asked 1/19/2020 10:39:18 AM
add a comment

1 Answers

0
Yes, it's pretty straightforward. You can do the following steps: ## First time ever download - Set your initial offset to 0 and use `public long DownloadFile( string remotePath, Stream outputStream, long remoteOffset )` or `public long DownloadFile( string remotePath, string localPath, long remoteOffset, long localOffset )` method to download to your local file - Save the number of downloaded bytes to a local var/DB ## Next downloads - Use the above mentioned download method with the remoteOffset and localOffset set to your saved var to download
 
answered 1/24/2020 9:37:51 AM
add a comment

Your Answer

Not the answer you're looking for? Browse other questions tagged sftp or ask your own question.