Hi,
I have a simple HTTP client in PL/SQL procedure with code like this:
UTL_HTTP.set_transfer_timeout(1); /* 1 second */
l_req := UTL_HTTP.begin_request(l_url);
l_resp := UTL_HTTP.get_response(l_req);
The problem is that if this procedure is called at a time with 950 milliseconds or higher, it sometimes raises timeout exception almost immediately.
example 1:
start at 46.996, timeout at 47.003 -> Wrong: duration is 0.006 milliseconds, but timeout is set to 1 second.
example 2:
start 26.952, timeout at 27.957 -> OK: duration is ~1 second.
Statistically it happens for 0.05% of requests between 0.950-1.000 seconds.
How to address this problem?
Thanks