[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: TCP connection timeout



If you think that the program is not closing the connection, create debug files.
 
If you turn on debugging, the last line in the file should be:
http_close(): entered
Things could not close for some really strange reason, but seeing this message is a good sign that a close was attempted.

Here is a suggestion:
Create a new directory.
Create a unique descriptive or random name for the files.
Turn on debug using directory/name.

After you experience the timeout, you can check the last debug file and see if it was closed or has other clues. If not, hopefully something is in there to say what went wrong.

After a while if the directory is filling up, run this in QSH:
grep -l http_close /directory/*.* |while read line; do rm $line; done  

That will remove any files that have "http_close" in them (the ones we aren't interested in).
 
Also, the latest Beta appears to be good. If you are on an earlier release, upgrade - relatively painless with no known problems.


> -----Original Message-----
> From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:ftpapi-
> bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Jim Bostwick
> Sent: Monday, March 28, 2011 1:35 PM
> To: ftpapi@xxxxxxxxxxxxxxxxxxxxxx
> Subject: TCP connection timeout
> 
> We are using HTTPAPI (1.23) 'http_url_post_stmf' to get information
> from a
> 3rd party and it has been working really well for several years.  We
> recently migrated to a new power 7 system and have noticed that the TCP
> connections are not being closed in our application when the RPG pgm
> ends,
> but rather after they timeout via the iSeries TCP settings (currently
> set to
> 120 seconds).  We run these requests via a single threaded jobq in
> batch,
> but they are running so fast now, that we are seeing occasional timeout
> errors, and I am thinking it may be because we are hitting the 3rd
> party
> site with another request, while we already have several earlier
> requests
> that have not yet 'timed out'.
> 
> 
> 
> Is this something that may be fixed in the current beta, or is there
> something that I can change in our RPG program to force the connection
> to
> close when it ends?
> 
> Jim

-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------