using Conga to do non-passive mode FTP

APL-related discussions - a stream of APL consciousness.
Not sure where to start a discussion ? Here's the place to be
Forum rules
This forum is for discussing APL-related issues. If you think that the subject is off-topic, then the Chat forum is probably a better place for your thoughts !

using Conga to do non-passive mode FTP

Postby jGoff on Wed Feb 17, 2010 2:41 pm

Anyone doing non-passive mode FTP using Conga?
If so, can you post a sample script?
If not, do you know whether it is supported.

Thanks,

J. Goff

P.S. I'm not pretending to know what these modes really are. To my mind it's just one of those niggling parameters that has to be set correctly in order to FTP successfully.
jGoff
 
Posts: 26
Joined: Fri Jun 19, 2009 12:25 pm

Re: using Conga to do non-passive mode FTP

Postby Dick Bowman on Thu Feb 18, 2010 7:58 am

I'll join you in saying that I also don't know what these modes really are.

But, to put on record a little experience with FTP the Conga way.

I have a little application which regularly picks up some files through FTP, at first I set it to do the FTP as a "command mode" task (create a file containing the FTP commands, fire off a task with quadCMD). That worked quite well, but had a rather shabby look-and-feel (with command prompt windows popping up).

Decided to bring it "in house" to make it look that bit tidier, so used the FTPClient example in Conga (also gave me the chance to learn a little). With APL/W 12.0 (maybe 11 as well - memory is fading) the transfers were noticeably slower than my earlier primitive approach (two or three times slower - at least). Something else that would happen from time to time was a timeout (Conga stopped - I'm not smart enough to rewrite FTPClient, just using it as a convenient tool). I think I briefly contemplated another approach, but word from Dyalog was "use Conga" (I paraphrase, or maybe fantasize).

Now using the same Conga/FTPClient approach with APL/W 21.1 and 64-bit Windows 7 (Conga has changed for 12.1) - the relative slowness is still there (I'd say it's quicker than before) and I haven't seen the timeout issue. It seems reliable, and I am happy to let it chug its way through the files. Maybe there's an issue with the site I'm retrieving from, I haven't experimented with anything outside the task in hand.

For now, for my purposes, Conga/FTPClient is doing the job. If it was a critical application with higher amounts of data I'd be inclined to do things the old-fashioned way (and maybe open up a dialogue with Dyalog) about performance.
Visit http://apl.dickbowman.com to read more from Dick Bowman
User avatar
Dick Bowman
 
Posts: 235
Joined: Thu Jun 18, 2009 4:55 pm

Re: using Conga to do non-passive mode FTP

Postby harsman on Thu Feb 18, 2010 8:52 am

FTP is a really old protocol and is, in general, insane.

For example, when using non passive FTP, the client connects to the server on the standard FTP port, port 21 and then the server opens a socket to the client on a port of the clients choosing. Besides being utterly insane, this won't work over NAT or a firewall which is why everyone tends to use passive mode FTP.

Lets not even go into stuff like the fact that the LIST command doesn't specify the format of what it outputs, the fact that user credentials are sent in plain text on an unencrypted connection or the epic fail of binary vs text mode.

FTP probably made sense 30 years ago, today not so much.
harsman
 
Posts: 27
Joined: Thu Nov 26, 2009 12:21 pm

Re: using Conga to do non-passive mode FTP

Postby Dick Bowman on Thu Feb 18, 2010 2:11 pm

Has anything replaced FTP for the simple "get me this file" tasks?
Visit http://apl.dickbowman.com to read more from Dick Bowman
User avatar
Dick Bowman
 
Posts: 235
Joined: Thu Jun 18, 2009 4:55 pm

Re: using Conga to do non-passive mode FTP

Postby harsman on Tue Feb 23, 2010 10:56 am

For most uses I'd say HTTP has replaced FTP. Downloading something over ftp is very rare these days. If you need encryption and authentication then SFTP is a more modern replacement for FTP.
harsman
 
Posts: 27
Joined: Thu Nov 26, 2009 12:21 pm

Re: using Conga to do non-passive mode FTP

Postby Dick Bowman on Mon Apr 12, 2010 1:13 pm

If anyone is still interested in this (and making sense of .Net), I've just added a little more Dyalog-specific content to Simon Marsden's page about APLX/FTP/Net on the APL Wiki (see http://aplwiki.com/UsingDotNetFTPfromAPLX).

Maybe the clunkiness is part of the charm...

I haven't done any serious timing tests, but it does seem to be grabbing my little tranche of files faster than had been the case when I used FTPClient from Conga - but maybe that's a result of my ever-optimistic coding.

Whether the code will stand the test of serious use without further modification remains to be seen...
Visit http://apl.dickbowman.com to read more from Dick Bowman
User avatar
Dick Bowman
 
Posts: 235
Joined: Thu Jun 18, 2009 4:55 pm

Re: using Conga to do non-passive mode FTP

Postby PhilGray on Fri Sep 03, 2010 10:46 pm

I was experimenting with the Conga WS ( from Oct 19 12:13:38 2009 )as follows :

Tried to upload a 600KB Binary file to an FTP server, and got a Value Error here :

WS : CONGA
.....FTPClient
........PutData[7] :If 0=⊃(r conn)←DRC.Client''Host DataPort type(10+⍴Data)

DRC.Client = VALUE ERROR

I just made quick guess that it was supposed to have been coded "DRC.Clt" ( already defined and used elsewhere ) ... so I changed the code but got a timeout on the upload.
( I reset the timeout to 120000 .. but same result )

Thoughts anyone ?
PhilGray
 
Posts: 50
Joined: Sat Mar 13, 2010 7:55 pm

Re: using Conga to do non-passive mode FTP

Postby PhilGray on Sat Sep 04, 2010 3:59 pm

I disabled my own Firewall ... to no effect .. Timeout still happens.
PhilGray
 
Posts: 50
Joined: Sat Mar 13, 2010 7:55 pm

Re: using Conga to do non-passive mode FTP

Postby kai on Sun Sep 05, 2010 7:23 am

Phil,

In Conga (DRC that is) the name was originally "Client". In order to improve readability that was changed to "Clt in Conga 2.0. When the workspace Conga still contains code that uses "Client" it seems that this part of the workspace was not adapted to the latest Conga version. I wouldn't be too surprised if this is causing your trouble.

Would DRC have been a class with a clearly defined interface and a rule saying something along the lines "You may enhance an interface but NEVER change (rename etc) it...

Regarding FTP in general: no doubt ftp is insane, I agree. But there is also no doubt that FTP is still important, and it will remain so for many years to come simply because there are so many FTP servers.

Can you upload a file with http?
User avatar
kai
 
Posts: 137
Joined: Thu Jun 18, 2009 5:10 pm
Location: Hillesheim / Germany

Re: using Conga to do non-passive mode FTP

Postby PhilGray on Sun Sep 05, 2010 9:27 am

Can you upload a file with http?


AFAIK this depends on the web-server : ASP, JSP, Apache etc.
That makes things less "general", which is not my desire.

Maybe I am using an out-of-date Conga WS (or DRC version) ?

CONGA saved Mon Oct 19 12:13:38 2009


Is there a more up-to-date version of Conga ?
PhilGray
 
Posts: 50
Joined: Sat Mar 13, 2010 7:55 pm

Next

Return to APL Chat

Who is online

Users browsing this forum: No registered users and 1 guest