Forum OpenACS Q&A: Re: NaviServer stops serving connections when slow external api calls pile up.

Hi Tony,

we will try to help. What I read from your posting:
- you have no reliable way to reproduce the problem (being able to reproduce the issue at our side would help significantly)
- Only some ns_http requests have "-timeout" specified
- are all requests over HTTPS?
- is there anything special about the jira service (running on a signe/multiple servers, restarts/reboots at the time when problems happen, ...)?

removed the http url from the logs below. which messed up some of the times below
I don't understand what "messed up" means here. If you do not want to reveal the URL on a public site, just replace it by "127.0.0.1". If there are very long URLs, this is also important for debugging. In the log above, there are just 408 status codes. Is this really all? I need as well the success cases to get a full picture, to see parallel requests, typical answer times, etc. Can you mail the log to me?

Do you have a monitoring of the VM running? It is interesting to see the VM-size, the memory statistics etc. There are cases, where the full VM hangs, where you cannot do anything from a single process point of view, when the full process does not get CPU at all. The example in https://openacs.org/forums/message-view?message_id=5539060 shows a case, where the full process is stopped for 6 seconds simply because of a fork() happening in a Tcl pipe-open command just depending on the memory size of the process. This blocked can be much larger depending on the circumstances, there can be many other factors influencing such cases (e.g., file-system, etc.). When the whole process is stopped by the kernel for, e.g., 10 seconds, setting a timeout of 1 second does have the desired effect. To identify such cases it is not sufficient to look at a single thread, but necessary to know what's happening in the other threads (if there is something happening) and maybe also, what's happening on the machine at this time.

What are your version numbers of
- OpenSSL
- NaviSever

all the best
-gn