Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Keeping a "move files" process open for full day

Nonamer wrote:

Keepuptodate will not delete from remote site

Use -delete switch

synchronize updates the whole structure, not just one folder.

Use file mask to narrow the synchronization.

How could I move away from this billion-session-openings solution, e.g. open session once and before running the put/get, to check whether the connection exists and reopen if it is down.

Use WinSCP .NET assembly:
https://winscp.net/eng/docs/library
Nonamer

Keeping a "move files" process open for full day

Keepuptodate will not delete from remote site, synchronize updates the whole structure, not just one folder.

Therefore I use Put- delete to operate a 1-minute interval polling file transfer task. It is dumb, right?

How could I move away from this billion-session-openings solution, e.g. open session once and before running the put/get, to check whether the connection exists and reopen if it is down.
martin

Re: Create a Session from the command line interface

Not sure what to suggest, not knowing your complete workflow.

But in general, you should assemble one script file with list of all files to be uploaded and than execute the script at once.
Ranger1230

Create a Session from the command line interface

What I want to do is have my program be able to use WinSCP to ftp a file to a server.
I was told that having it create a new temporary session every time I go to upload a file was bad for performance and would cause issues with the server. as a result I'm trying to find a way to check if a session exists if not save one with the given settings, if it does use it to upload the file.

Is there away to do this?