Hi Peter,
Replying to a message of Peter Knapper to David Noon:
PK> When talking to Francois Massonneau recently the subject of performing
PK> a PING came up, so you may have an answer for this.
PK> Most of the REXX FTP functions appear to be implemented with some
PK> quite lengthy timeouts, and it can take 1-2 minutes to decide that
PK> the remote end is not contactable. I tried to "test" for this using a
PK> single FtpPing, however if the destination/target system is not
PK> contactable, FtpPing suffers from the same long timeout. Do you know
PK> of a way to alter the REXX FTP timeout period to something like 10-20
PK> seconds rather than 2 minutes?
You can certainly do this with raw socket functions. A ping is simply a RPC to
the remote host, and you can specify your timeout in which you expect that RPC
to respond. There is sample code in the OS/2 Warp 4 Developer's Toolkit
documentation for the OS/2 TCP/IP Toolkit 4.1 that will get you started.
PK> Alternatively, can you (or someone else) suggest some REXX Sockets
PK> code to perform the equivalent task, if the timeout periods can be
PK> controlled from there?
I don't know much about RxSock.DLL, but I would doubt that it would offer such
a low level API. I think you will need to use a compiler or assembler to do
this. Of course, you can always wrap the resulting code in a few lines of REXX
calling interface and make it an extension DLL.
Regards
Dave
--- FleetStreet 1.24.1
* Origin: The man who broke the bank at Monte Carlo (2:257/609.5)
|