It is just the connection that times out after 5000ms.
The SAPs network interface and ICM is simply returning an error of the OS network functions as for the connection to an specific IP:PORT that could not be completed.
Besides of the application availability, this could also be an issue of the network or of the remote server, e.g. an overloading issue.
You could increase the ICM connection establishment timeout to 15 seconds, e.g.:
icm/conn_timeout = 15000
Regards,
Americo.